Frequently Asked Questions

Technical Integration & Getting Started

How can I use Hygraph as a database in my Go applications?

Hygraph can be used as a database in Go programs by leveraging its GraphQL API. Developers can query Hygraph directly within their Go applications using packages like machinebox/graphql. The official Hygraph endpoint is open for querying, and you can find a full code example for Go integration here. For more details, see the API Reference.

Where can I find code examples for integrating Hygraph with Go?

You can find quickstart code examples for integrating Hygraph with Go on GitHub. These examples demonstrate how to set up your Go project, connect to the Hygraph GraphQL API, and query data efficiently.

Is authentication required to query Hygraph's public API endpoint?

No authentication is required to query Hygraph's public API endpoint for the example provided in the Go tutorial. The endpoint is open for querying, making it easy to get started with development and testing. For production use, refer to the API documentation for authentication and error handling best practices.

Where can I find technical documentation for Hygraph?

Comprehensive technical documentation for Hygraph is available at Hygraph Documentation. This resource covers API usage, integration guides, troubleshooting, and best practices for building and deploying projects with Hygraph.

How can I get started with Hygraph quickly?

To get started with Hygraph, sign up for a free-forever account at our platform. You can also explore quickstart guides on GitHub and YouTube. For a walkthrough of the interface and API, watch this video.

Features & Capabilities

What features does Hygraph offer?

Hygraph offers a GraphQL-native architecture, content federation, scalability, and a wide range of integrations including Netlify, Vercel, BigCommerce, Shopify, Lokalise, Cloudinary, and more. It supports rapid content delivery, robust security, and an intuitive interface for both technical and non-technical users. For a full list of features, visit Hygraph Features.

Does Hygraph provide an API for content management?

Yes, Hygraph provides a powerful GraphQL API for efficient content fetching and management. The API enables flexible querying and integration with various frameworks and languages, including Go. Learn more at the API Reference.

What integrations are available with Hygraph?

Hygraph supports integrations with hosting and deployment platforms (Netlify, Vercel), eCommerce solutions (BigCommerce, Shopify), localization tools (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. For a complete list, visit Hygraph Integrations.

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. For more details, visit this page.

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 full details and feature breakdowns, visit the 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. For more details, visit Hygraph Security Features.

Use Cases & Customer Success

Who can benefit from using Hygraph?

Hygraph is ideal 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 their tech stack, and brands aiming to scale across geographies or improve development velocity. Source: ICPVersion2_Hailey.pdf

What 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. For more, visit Hygraph Case Studies.

Can you share specific customer success stories using Hygraph?

Yes. Komax achieved a 3X faster time to market, Autoweb saw 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 success stories here.

Who are some of Hygraph's customers?

Hygraph is trusted by companies such as Sennheiser, HolidayCheck, Ancestry, Samsung, Dr. Oetker, Epic Games, Bandai Namco, Gamescom, Leo Vegas, and Clayton Homes. For more details and logos, visit Hygraph Case Studies.

Pain Points & Solutions

What problems does Hygraph solve?

Hygraph addresses operational pains (reliance on developers for content updates, outdated tech stacks, conflicting needs from global teams, clunky user experiences), financial pains (high operational costs, slow speed-to-market, expensive maintenance, scalability challenges), and technical pains (boilerplate code, overwhelming queries, evolving schemas, cache problems, OpenID integration challenges). For more details, visit our product page.

How does Hygraph solve pain points for different personas?

Hygraph tailors solutions for developers (reducing boilerplate code, streamlining queries, adapting to evolving schemas), content creators/project managers (intuitive interface for independent content updates), and business stakeholders (lower operational costs, scalability, faster speed-to-market). For more, visit our product page.

What KPIs and metrics are associated with the pain points Hygraph solves?

Key metrics include time saved on content updates, system uptime, speed of deployment, consistency in content across regions, user satisfaction scores, reduction in operational costs, time to market, maintenance costs, scalability metrics, and performance during peak usage. For more details, visit our blog on CMS KPIs.

Support & Implementation

What support and training does Hygraph offer?

Hygraph provides 24/7 support via chat, email, and phone. Enterprise customers receive dedicated onboarding and expert guidance. All users have access to documentation, video tutorials, webinars, and a community Slack channel. For more, visit Hygraph Contact Page.

How long does it take to implement Hygraph?

Hygraph is designed for quick implementation. For example, Top Villas launched a new project in just 2 months from initial contact. Non-technical users can get started quickly using onboarding guides and documentation. Learn more at Hygraph Documentation.

What customer feedback has Hygraph received regarding ease of use?

Customers praise Hygraph for its ease of use and intuitive interface, noting that 'even non-technical users can start using it right away.' The UI is described as logical and user-friendly, making it accessible for both technical and non-technical teams. Source: Hygraph Try Headless CMS.

Vision & Mission

What is Hygraph's vision and mission?

Hygraph's vision is to unify data and enable content federation, empowering businesses to create impactful digital experiences. Its mission is to remove traditional content management pain points through a GraphQL-native architecture, helping businesses modernize their tech stacks and deliver exceptional digital experiences at scale. Source: About Us.

Velocity at Scale: Join the Launch of Hygraph’s Latest AI Innovations

Getting Started with Go and Hygraph

As more people use "Hygraph as a Database", we'll explore how to query Hygraph inside of your Go program.
Jamie Barton

Written by Jamie 

Jun 25, 2021
Working with GraphCMS and GO

Go is an open-source programming language that has seen significant adoption over the last few years and has become the backbone to many banks, businesses, and API platforms across the world.

As more people use "Hygraph as a Database", just like we saw with working with Express.js, we can query Hygraph just like we would any other database. Go has no opinion on where your data comes from, just as long as you structure your data access the right way.

We'll use Go modules, and since I don't plan to use this as a package I can share with others, I'll just name it with-golang.

go mod init using-golang

Then using Go modules I'll go get the graphql client package by Gopher Mat Ryer, and Machinebox.

go get github.com/machinebox/graphql

Now let's begin writing our Go program!

touch main.go

Inside there you'll want to declare the main package, import our GraphQL client module we just installed, and define a client variable.

ℹ️ If you're using Visual Studio Code, you can install the Go extension, which will automatically format (fmt), and do its best to manage your imports as and when you use them.

package main
import "github.com/machinebox/graphql"
var client *graphql.Client
func main() {
// ...
}

Let's now create a function for setupClient() and assign it to the client variable.

func setupClient() {
client = graphql.NewClient("https://api-eu-central-1.hygraph.com/v2/ck8sn5tnf01gc01z89dbc7s0o/master")
}

ℹ️ The endpoint above is open to all for querying, so no authentication is required.

Before we can use the client to make a NewRequest to Hygraph, it's best we define a struct for our Product, and Response.

You don't need to do this, but Go would much prefer you to. 😉

The first struct for Product will contain our name, description, and price fields we have in our Hygraph schema. We'll assign these to string, string, and int respectively.

While we're at it, we'll specify the json format of these too.

type Product struct {
Name string `json:"name"`
Description string `json:"description"`
Price int `json:"price"`
}

Next, let's define the ProductResponse, you could call this QueryResponse but this will define the shape of the response from Hygraph. This must match our GraphQL query.

type ProductResponse struct {
Products []Product `json:"products"`
}

ℹ️ You might want to format and account for any errors here too.

Let's now create a function getAllProducts() where we will make our request to client.

Our query must match the struct of Product and ProductResponse above.

func getAllProducts() {
query := graphql.NewRequest(`
{
products {
name
description
price
}
}
`)
ctx := context.Background()
var responseData ProductResponse
if err := client.Run(ctx, query, &responseData); err != nil {
log.Fatal(err)
}
}

You could define your query outside of this and pass it into a new function, and instead of using context you could use the context of a http request if you ran this code as an HTTP handler.

But for now, let's add a bit more to this function to print our response as JSON.

jsonResponse, _ := json.MarshalIndent(responseData, "", "\t")
fmt.Printf("%+v\n", string(jsonResponse))

Then all that's left to do is update the main function to call both our functions.

func main() {
setupClient()
getAllProducts()
}

That's it! Give it a try via your terminal:

go run main.go

Here's the full main.go file, including the imports:

package main
import (
"context"
"encoding/json"
"fmt"
"log"
"github.com/machinebox/graphql"
)
type ProductResponse struct {
Products []Product `json:"products"`
}
type Product struct {
Name string `json:"name"`
Description string `json:"description"`
Price int `json:"price"`
}
var client *graphql.Client
func setupClient() {
client = graphql.NewClient("https://api-eu-central-1.hygraph.com/v2/ck8sn5tnf01gc01z89dbc7s0o/master")
}
func getAllProducts() {
query := graphql.NewRequest(`
{
products {
name
description
price
}
}
`)
ctx := context.Background()
var responseData ProductResponse
if err := client.Run(ctx, query, &responseData); err != nil {
log.Fatal(err)
}
jsonResponse, _ := json.MarshalIndent(responseData, "", "\t")
fmt.Printf("%+v\n", string(jsonResponse))
}
func main() {
setupClient()
getAllProducts()
}

I hope you found this useful, and to learn more about using Go with Hygraph, I recommend you check the README on GitHub for github.com/machinebox/graphql.

Get the code for this article on GitHub.

Blog Author

Jamie Barton

Jamie Barton

Jamie is a software engineer turned developer advocate. Born and bred in North East England, he loves learning and teaching others through video and written tutorials. Jamie currently publishes Weekly GraphQL Screencasts.

Share with others

Sign up for our newsletter!

Be the first to know about releases and industry news and insights.