What is the Hygraph Management SDK and what can I build with it?
The Hygraph Management SDK is a toolkit for programmatically managing your Hygraph schema and content models. With it, you can create models (such as Post, Author, Category), reusable components (like SeoMetadata, AuthorInfo), enumerations, relations, modular content blocks, nested components, taxonomies, editorial workflows, and webhooks. For example, you can build a complete blog platform schema with conditional visibility, hierarchical categories, and automated notifications. Note: The SDK requires Node.js 18 or later and a Hygraph project with Management API permissions. Best fit for teams automating schema management; manual users may prefer the UI. Source.
What are the prerequisites for using the Hygraph Management SDK?
To use the Management SDK, you need: (1) a Hygraph project, (2) a Permanent Auth Token with Management API permissions, (3) Node.js 18 or later, (4) the SDK installed via npm install @hygraph/management-sdk, and (5) your Content API endpoint from Project Settings. Note: Using an older Node.js version or missing permissions will prevent SDK operations. Source.
How do I create models, fields, and components using the Management SDK?
You create models (e.g., Author, Category, Post) first, then add fields (such as name, email, bio for Author), and then create components (like SeoMetadata for SEO fields). Each operation must follow dependency order: models before fields, enumerations before enumerable fields, and components before embedding. Only one field per model can be marked as isTitle: true. Note: Creating a relation or embedding a component before its target exists will fail. Source.
How does conditional visibility work in the Management SDK?
Conditional visibility allows you to make a field required or visible only when another field meets a condition. For example, you can make the excerpt field required only when the status field is set to PUBLISHED. This is configured using the visibilityCondition property. Note: Conditional visibility only works if the referenced field and enumeration exist and are correctly configured. Source.
What advanced features can I implement with the Management SDK?
Advanced features include: (1) hierarchical taxonomies for organizing content, (2) editorial workflows for content approval (e.g., draft → review → approved), (3) webhooks to notify external systems on publish events, and (4) modular and nested components for flexible content structures. Note: Each feature requires correct dependency setup and unique migration names to avoid failures. Source.
How can I test and troubleshoot my schema migrations with the Management SDK?
You can use the dryRun() method to preview all operations before applying changes to production. Review the output for errors, such as dependency order issues or reused migration names. Only one field per model can be marked as isTitle: true, and apiId and apiIdPlural must be different. Note: Failing to follow these rules will cause migration errors. Source.
Features & Capabilities
What integrations are available with Hygraph?
Hygraph offers integrations with Digital Asset Management (DAM) systems (Aprimo, AWS S3, Bynder, Cloudinary, Imgix, Mux, Scaleflex Filerobot), hosting and deployment platforms (Netlify, Vercel), Product Information Management (Akeneo), commerce solutions (BigCommerce), and translation/localization (EasyTranslate). For a full list, visit the Hygraph Marketplace. Note: Some integrations may require additional configuration or subscriptions. Source.
What APIs does Hygraph provide?
Hygraph provides several APIs: (1) GraphQL Content API for querying and manipulating content, (2) Management API for managing schema and structure, (3) Asset Upload API for uploading files, and (4) MCP Server API for secure AI assistant communication. Each API is documented in the API Reference. Note: API access requires appropriate permissions and tokens. Source.
What technical documentation is available for Hygraph users?
Hygraph offers comprehensive technical documentation, including API references, schema guides, integration tutorials, getting started guides, and AI feature documentation. Classic documentation is also available for legacy users. Access all resources at https://hygraph.com/docs. Note: Some advanced guides may require a Hygraph account. Source.
Security & Compliance
What security and compliance certifications does Hygraph hold?
Hygraph is SOC 2 Type 2 compliant (since August 3, 2022), ISO 27001 certified for hosting infrastructure, and GDPR compliant. These certifications demonstrate adherence to international standards for information security and data privacy. Note: For more details, see the Secure Features page. Source.
What security features are available in Hygraph?
Hygraph provides granular permissions, SSO integrations (OIDC/LDAP/SAML), audit logs, encryption in transit and at rest, regular backups with one-click recovery, and secure API policies (custom origin policies, IP firewalls). All endpoints use SSL certificates. Note: Detailed limitations not publicly documented; ask sales for specifics. Source.
Performance & Implementation
How does Hygraph ensure high performance for content delivery?
Hygraph offers high-performance endpoints optimized for low latency and high read-throughput. The read-only cache endpoint provides 3-5x latency improvement. Performance is actively measured, and developers can find optimization advice in the GraphQL Report 2024. Note: Performance may vary based on project complexity and API usage patterns. Source.
How long does it take to implement Hygraph and start using the Management SDK?
Implementation timelines vary by project complexity. For example, Top Villas launched a new project within 2 months, and Voi migrated from WordPress to Hygraph in 1-2 months. Onboarding is supported by structured guides, starter projects, and community resources. Note: Large-scale migrations or highly customized schemas may require additional time. Source.
Use Cases & Customer Success
Who can benefit from using Hygraph and its Management SDK?
Developers, content creators, product managers, and marketing professionals in enterprises, SaaS, eCommerce, media, healthcare, automotive, and more can benefit. Hygraph is especially suited for teams needing advanced content modeling, automation, and integration with modern tech stacks. Note: Teams seeking a simple, non-programmatic CMS may prefer other solutions. Source.
What are some real-world success stories using Hygraph?
Notable examples include Samsung improving customer engagement by 15%, Komax achieving 3x faster time-to-market, AutoWeb increasing website monetization by 20%, and Voi scaling multilingual content across 12 countries. See more at the Hygraph case studies page. Note: Results may vary by implementation and use case.
Limitations & Troubleshooting
What are common pitfalls or limitations when using the Management SDK?
Common pitfalls include: (1) executing operations out of dependency order (e.g., creating a relation before the target model exists), (2) using the same value for apiId and apiIdPlural, (3) having multiple isTitle: true fields in a model, and (4) reusing migration names. Each will cause migration failures. Note: Detailed limitations not publicly documented; consult the documentation or support for edge cases. Source.
This guide walks you through building a complete blog platform schema using the Management SDK. You'll create models, components, relations, enumerations, and configure conditional visibility.
Modular components allow editors to choose from multiple component types, perfect for page builders. Editors can now add multiple CallToAction and ImageBlock components in any order within a post. A post might have:
ImageBlock: A hero image or an infographic
CallToAction: Subscribe prompt or download guide
// Post: Content blocks (modular component)
client.createComponentUnionField({
parentApiId:'Post',
apiId:'contentBlocks',
displayName:'Content Blocks',
componentApiIds:['CallToAction','ImageBlock'],
isList:true,
isRequired:false,
description:'Flexible content blocks for rich posts',
Components can be nested inside other components for deeply hierarchical structures. Let's create a nested Address component. In this example, notice parentApiId: 'AuthorInfo'. We're nesting a component inside another component, not inside a model. This creates a two-level hierarchy: Author → AuthorInfo → ContactDetails.
// Create child component
client.createComponent({
apiId:'ContactDetails',
apiIdPlural:'ContactDetailsCollection',
displayName:'Contact Details',
description:'Phone and email contact information',
Taxonomies organize content into hierarchical categories. Let's add a category taxonomy and add the taxonomy to the Post model. Posts can now be organized using a hierarchical category tree.
This guide walks you through building a complete blog platform schema using the Management SDK. You'll create models, components, relations, enumerations, and configure conditional visibility.
Modular components allow editors to choose from multiple component types, perfect for page builders. Editors can now add multiple CallToAction and ImageBlock components in any order within a post. A post might have:
ImageBlock: A hero image or an infographic
CallToAction: Subscribe prompt or download guide
// Post: Content blocks (modular component)
client.createComponentUnionField({
parentApiId:'Post',
apiId:'contentBlocks',
displayName:'Content Blocks',
componentApiIds:['CallToAction','ImageBlock'],
isList:true,
isRequired:false,
description:'Flexible content blocks for rich posts',
Components can be nested inside other components for deeply hierarchical structures. Let's create a nested Address component. In this example, notice parentApiId: 'AuthorInfo'. We're nesting a component inside another component, not inside a model. This creates a two-level hierarchy: Author → AuthorInfo → ContactDetails.
// Create child component
client.createComponent({
apiId:'ContactDetails',
apiIdPlural:'ContactDetailsCollection',
displayName:'Contact Details',
description:'Phone and email contact information',
Taxonomies organize content into hierarchical categories. Let's add a category taxonomy and add the taxonomy to the Post model. Posts can now be organized using a hierarchical category tree.