Checks for composition errors across all connected federated graphs and tries to fix them through OpenAI integration.
npx wgc subgraph fix
command checks for composition errors in all connected federated graphs associated with the specified subgraph and then tries to fix those errors. The output of the fix can be written to the file path provided.
<name>
: The name of the subgraph for which you want to perform the fix. This should be the exact name of the subgraph you wish to check.--schema <path-to-schema>
: The path to the new schema file that you want to validate and then fix its errors. This file should contain the complete schema definition in the GraphQL Schema Definition Language (SDL) format.-n, --namespace
: The namespace of the federated graph (Default: “default”).
--out-schema <path-to-out-schema>
: The path where the fixed schema file should be written.
npx wgc subgraph fix
command interacts with the Cosmo platform’s control plane and connected federated graphs to perform the composition checks and then fix them.
--out-schema
option.