What is Hygraph and what are its core capabilities?
Hygraph is a GraphQL-native headless content management system (CMS) designed to unify data and enable content federation. Its core capabilities include content federation, scalability, and a unique GraphQL API for efficient data querying. Hygraph empowers businesses to create impactful digital experiences by removing traditional content management pain points and supporting modern development workflows. Learn more.
Does Hygraph support integration with third-party databases like FaunaDB?
Yes, Hygraph supports integration with third-party databases such as FaunaDB through its Content Federation and Remote Sources features. This allows you to combine product information from Hygraph with external data sources like FaunaDB for product reviews, enabling seamless data retrieval via a single GraphQL API call. Read the integration guide.
What types of integrations does Hygraph offer?
Hygraph offers a wide range of integrations, including hosting and deployment (Netlify, Vercel), headless commerce (BigCommerce, commercetools, Shopify), localization (Lokalise, Crowdin, EasyTranslate, Smartling), digital asset management (Aprimo, AWS S3, Bynder, Cloudinary, Mux, Scaleflex Filerobot), personalization and AB testing (Ninetailed), artificial intelligence (AltText.ai), and more. See the full list of integrations.
Does Hygraph provide an API for content management?
Yes, Hygraph provides a powerful GraphQL API that allows you to fetch and manage content efficiently. This API supports advanced querying and is central to Hygraph's content federation and integration capabilities. Learn more about the API.
How does Hygraph enable content federation in e-commerce?
Hygraph's Content Federation feature allows you to reference product information from commerce systems like Shopify, BigCommerce, or commercetools directly within Hygraph. This means you can display product details, pricing, categories, and images on your site without duplicating content, streamlining omnichannel e-commerce experiences. Learn more about Content Federation.
Use Cases & Customer Success
How can I combine FaunaDB reviews with Hygraph e-commerce data?
You can combine FaunaDB reviews with Hygraph e-commerce data by setting up FaunaDB as a remote GraphQL source in Hygraph. This involves creating a FaunaDB database for reviews, exposing it via a GraphQL endpoint, and configuring Hygraph to fetch review data using the product's unique identifier. This setup allows you to display product reviews alongside product information in your e-commerce application. See the step-by-step guide.
What are some real-world success stories of companies using Hygraph?
Hygraph has enabled companies like Komax to achieve a 3X faster time to market and Autoweb to realize a 20% increase in website monetization. Samsung improved customer engagement with a scalable platform, and Dr. Oetker enhanced their digital experience using MACH architecture. Explore more customer stories.
Which industries are represented in Hygraph's case studies?
Hygraph's case studies span industries such as food and beverage (Dr. Oetker), consumer electronics (Samsung), automotive (AutoWeb), healthcare (Vision Healthcare), travel and hospitality (HolidayCheck), media and publishing, eCommerce, SaaS (Bellhop), marketplace, education technology, and wellness and fitness. See all case studies.
Technical Requirements & Implementation
How do I set up a remote source in Hygraph?
To set up a remote source in Hygraph, go to your project’s Schema view, add a new Remote Source, select GraphQL as the type, and provide the base URL and authorization headers for your external API (e.g., FaunaDB). You can then add a Remote Source Field to your content model to fetch data from the external source using a unique identifier. Read the detailed setup instructions.
What technical documentation is available for Hygraph?
Hygraph provides comprehensive technical documentation covering setup, integrations, API usage, and advanced features. This documentation is suitable for both developers and non-technical users. Access Hygraph Documentation.
How easy is it to get started with Hygraph?
Hygraph is designed for ease of use, with an intuitive interface praised by customers for being accessible to both technical and non-technical users. You can get started quickly by signing up for a free account and using resources like documentation, video tutorials, and onboarding guides. Get started with Hygraph.
Pricing & Plans
What is Hygraph's pricing model?
Hygraph offers a free forever Hobby plan, a Growth plan starting at $199/month, and custom Enterprise plans. For detailed pricing and feature breakdowns, visit the Hygraph pricing page.
Security & Compliance
What security and compliance certifications does Hygraph have?
Hygraph is SOC 2 Type 2 compliant, ISO 27001 certified, and GDPR compliant. These certifications ensure enterprise-grade security and data protection. Hygraph also offers SSO integrations, audit logs, encryption at rest and in transit, and sandbox environments. See Hygraph's security features.
Support & Customer Service
What support options are available for Hygraph customers?
Hygraph provides 24/7 support via chat, email, and phone. Enterprise customers receive dedicated onboarding and expert guidance. All users have access to detailed documentation, video tutorials, and a community Slack channel. Contact Hygraph support.
Performance & Business Impact
How does Hygraph optimize content delivery performance?
Hygraph emphasizes optimized content delivery performance, which improves user experience, engagement, and search engine rankings. Rapid content distribution and responsiveness help reduce bounce rates and increase conversions. Learn more about performance optimization.
What business impact can customers expect from using Hygraph?
Customers can expect significant business impacts, including time savings through streamlined workflows, faster speed-to-market, improved customer experience, and enhanced scalability. These benefits help businesses modernize their tech stack and achieve operational efficiency. See business impact details.
Target Audience & Use Cases
Who is the target audience for Hygraph?
Hygraph is designed for developers, IT decision-makers, content creators, project/program managers, agencies, solution partners, and technology partners. It is especially beneficial for modern software companies, enterprises seeking to modernize, and brands aiming to scale across geographies or re-platform from traditional solutions. Learn more about Hygraph's mission.
Customer Proof & Recognition
Who are some of Hygraph's notable customers?
Notable Hygraph customers include Sennheiser, HolidayCheck, Ancestry, Samsung, Dr. Oetker, Epic Games, Bandai Namco, Gamescom, Leo Vegas, and Clayton Homes. See more customer stories.
Combining FaunaDB reviews with Hygraph e-commerce data
In this demo, we’ll explore how to take the basic e-commerce starter and combine Hygraph product information with a third-party database for product reviews.
Written by Bryan
on Dec 14, 2022
While Hygraph works well for many types of content, sometimes, for a variety of reasons, not all your content will live in Hygraph. No worries, that’s why we have Content Federation and Remote Sources.
In this demo, we’ll explore how to take the basic e-commerce starter and combine Hygraph product information with a third-party database for product reviews. The same principles at play in this example will work with any other GraphQL API and Hygraph data.
To begin, we’ll set up a new database and collection in Fauna. To do this, sign up or log into your Fauna account and create a new database. We’ll call the database “reviews.” Inside this new database, create a Collection. The Collection can also be called reviews.
Once we have a database and Collection, we can add our first piece of data. Since Fauna is a NoSQL document store, we can create an object in the document.
We’ll add four data points for each review: reviewer name, rating, content, and product ID (which will match a Hygraph slug or ID or any unique identifier on the product data in Hygraph).
{
"rating":4,
"productId":"unisex-long-sleeve-tee",
"name":"Bryan Robinson",
"content":"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris ac cursus massa. Nam sit amet ornare justo. Proin faucibus mi et tellus finibus sodales. Phasellus consequat pulvinar neque ac tristique. Pellentesque nulla velit, scelerisque id ante quis, ultricies viverra arcu. Integer ac risus dictum, tempus urna non, eleifend sapien. Cras rhoncus lacus at ligula auctor aliquam. Nunc fringilla facilisis lorem quis rhoncus. Quisque convallis venenatis urna, a tincidunt urna convallis non. Suspendisse vitae cursus lorem. Integer tempor sed felis quis condimentum. Etiam vel ex lacinia, consequat sapien quis, dapibus lacus. In maximus dapibus mauris, id euismod ante tincidunt non. Donec in nunc pulvinar lacus faucibus pellentesque."
}
Fauna will automatically generate a custom ID and a time stamp for every object entered. Note the productId property. This lines up with the demo content in the e-commerce starter, but whatever identifier makes the most sense for your project can be used here. The rating is an integer, and the name and content are both strings.
From here, we have a Fauna database ready for querying. In order to use it most efficiently, we need to set up a GraphQL end point for our Collection.
Setting up a Fauna GraphQL endpoint
To set up a GraphQL endpoint, navigate in your Fauna dashboard to the GraphQL section. Nothing will be waiting for you. We need to add a schema for our data and a specific query to get our reviews. To do this, we upload a GraphQL schema file.
typeReview@collection(name:"reviews"){
name:String!
productId:String!
content:String
rating:Int!
}
typeQuery{
reviewsByHygraphSlug(productId:String!):[Review]
}
This is a fairly simple schema and query but note the @collection directive. This directive lets us keep associating a specific type with a collection name. If they were named exactly the same, we wouldn’t need this, but it can help to keep best practices from both GraphQL and Fauna in place and associate the two.
Now that we have a schema set up, we can run a quick query in the GraphQL playground inside Fauna to give it a try.
queryReviews($slug:String!){
reviewsByHygraphSlug(productId:$slug){
data{
name
rating
content
productId
}
}
}
With this query and the productId slug from the created document above, we can get a list of reviews with that productId. This means we can get it by the Hygraph slug from within Hygraph.
Add an Fauna API key
In order to use this data in Hygraph, we need an API. Head over to the “Security” page in Fauna and click “New key.”
Tell it which database to use (if you’re following along, there should only be one), and select a role. This key is fine to set up as a Server key, but you can also go into Roles and set up a custom role to keep permissions as granular as you need.
Once this is saved in, Fauna will display your key. This is the only time to copy it, so make sure to grab it before moving on. We’ll use that in our Remote Source in Hygraph.
While we could set up a separate API call to Fauna to get all the reviews at build or request time, it would be a much strong developer experience to only make one API call to Hygraph and get all the data we need for a given product. To do that, we can use Hygraph’s Remote Sources and Remote Source Fields.
To set this up, head over to your Hygraph project (ideally one created from this starter), and open up the Schema view.
Click “Add” under Remote Sources and fill out the following information:
Name the remote source “Fauna Reviews”
Select GraphQL for the remote source type
The Base URL is the GraphQL URL from your Fauna database (typically something like https://graphql.us.fauna.com/graphql )
Add an Authorization header set to Bearer <your-api-key>
Add this same header to the Introspection Headers
Click save
This creates a connection between Fauna’s GraphQL API and Hygraph. Once this is set up, we need to set up a GraphQL Remote Source Field for our products.
Navigate to the Product Schema. In the available Fields, there is now a “GraphQL Field.” Click this, and it’s time to set up the field to pull the correct data for each product.
Give the field a name and an API ID and in the “Query” builder, select “ReviewsByHygraphSlug” — the query we built in our schema for Fauna. Choose productId as the query argument. In the input below that checkbox select {{doc.slug}} which will pull the current document’s slug as the value to pass to that argument.
Once we have that, we could go ahead and query. However, our query would always require we get the data object off the response. This is an extra bit that we don’t have to deal with. Click the checkbox by “Data” in the “Fields” list. This will put the data in the root of the response from the query. Now the data will be available one level up — a small but pleasant improvement.
Now that we have this field saved, we can navigate to any product, and we can see the new “Fauna Reviews” field. The only thing it will display is a “Preview in Playground” link. If you’re using the default e-commerce starter data, you should have a product with a slug “unisex-long-sleeve-tee”. Navigate to that product and click the Preview button for the Fauna Reviews field.
This will take us to the API playground with the basic query to this item. We can expand the faunaReviews array with the data we require right next to additional information on the product itself.
querycontent_product_faunaReviews($id:ID!){
values:product(where:{id:$id}){
slug
name
faunaReviews{
name
rating
content
_ts
}
}
}
We don’t have to do any normalization, extra queries, or even pass in arguments in this call. It’s all combined for us by the GraphQL API in Hygraph. This data can now be used in the frontend to show reviews alongside all the product information.
Once you have this setup, you can add additional databases or data from Fauna. You could also pull product information in the same way from something like BigCommerce or Shopify — including using the new Shopify extension to help. The same could go for any third-party review application that has an API. As long as you have a unique identifier that can be entered into Hygraph, you can pull any additional information you need.
Blog Author
Bryan Robinson
Head of Developer Relations
Bryan is Hygraph's Head of Developer Relations. He has a strong passion for developer education and experience as well as decoupled architectures, frontend development, and clean design.
Share with others
Sign up for our newsletter!
Be the first to know about releases and industry news and insights.