Hi! In your docs it says that one can use the apollo-mcp-server with any API server, however when attempting to boot it without the graphos config it says:
``` Error: Missing environment variable: APOLLO_GRAPH_REF
```
Adding empty strings as those values in the config yields:
uplink error, the request will not be retried: code=AUTHENTICATION_FAILED message= did not parse to a valid key format
@chriss It should work with any GraphQL APIs. Could you let me know which version of apollo-mcp-server youâre using? Also, please share your config file, run the server with debug logging enabled, and provide the terminal output.
Hi Dale! Returning to this, I was able to figure it out!
Would be great if the âquickstartâ doc didnât link to the tutorial with all of its steps and complexity, but rather something more bare bones, with a full config easily readable.
For example, a config something like the below would be enough for most devs to get started within a locally-running GraphQL server:
Really glad to hear you got it working @chriss! Appreciate the feedback. Iâll pass it along to the team so we can make the quickstart experience clearer.
Hi chriss - could you share how you resolved this issue?
Using 0.6.1 I get the error âMissing environment variable: APOLLO_GRAPH_REFâ using a basic config setup.
If I set these env vars to dummy values, it will fail the validation: âERROR uplink error, the request will not be retried: code=UNKNOWN_REF message=No valid graph configuration for âŚâ
The new features in 0.6 look interesting, but without using federation this seems to be broken.
Sure thing! A config as simple as this will do it, assuming youâve booted your graphql server on port 5001, and started the MCP server. Note the bit about schema: source: local, which then points at the concrete artifact of your schema; once this is set the error will go away. Weâve also tested this on remotely deployed graphql servers and likewise, works great.
Hi @bwkiwi , as @chriss mentioned, Apollo MCP Server tries to fetch the schema from Uplink by default, which requires an Apollo key and a graph reference. This default behavior is documented here:
You can configure the MCP server to use your local schema file as follows:
schema:
source: local
path: /schema.graphql
Once you make this change, you should be able to start the server without needing Apollo-specific environment variables.