This example demonstrates how to use Tailcall with Apollo Federation by running multiple subgraphs and an Apollo router.
1. Start Tailcall subgraphs
Run the following commands to start the subgraph examples:
cargo run -- start examples/apollo_federation_subgraph_post.graphql
cargo run -- start examples/apollo_federation_subgraph_user.graphql
2. Run the Apollo router
You can run the router using one of these two methods:
Method A: Using @apollo/gateway
Navigate to the examples/federation folder and run:
npm install
npm start
Method B: Using Apollo Rover
If you have Apollo Rover installed, use the rover.sh script.
3. Access the Supergraph
Once the subgraphs and router are running, navigate to http://localhost:4000 to execute supergraph queries.