Home icon
AWS AppSync Merged APIs Best Practices: Part 2 – Schema Composition

Blog



This article covers best practices for designing schemas in AWS AppSync Merged APIs, which combine multiple GraphQL APIs into a unified interface.

  • Design Source APIs as independent microservices handling single domains with clear ownership
  • Define primary keys for each type to enable data relationships across Source APIs
  • Establish relationships between Source APIs using foreign keys for data joining
  • Document relationships through schema comments for developer clarity
  • Design Merged APIs for organization-wide use cases, not one-to-one UI mappings
  • Use @hidden directive to hide internal primary keys from Merged API clients
  • Resolve schema conflicts through team collaboration and renaming/redefining types
  • Use @canonical directive to designate authoritative data sources during conflicts
  • Establish Schema architect or working group for cross-team coordination

Effective schema design for Merged APIs requires careful planning around team ownership, data relationships, and conflict resolution to create scalable, intuitive unified GraphQL interfaces.



Go to article

The AWS News Feed is currently looking for gold sponsors. If you want to support the AWS community and reach a large audience of AWS professionals, consider sponsoring the AWS News Feed.

Related articles

The AWS News Feed is currently looking for silver sponsors. If you want to support the AWS community and reach a large audience of AWS professionals, consider sponsoring the AWS News Feed.