If we have a MongoDB database and app service for it, utilizing the Atlas GraphQL API, it autogenerates the GraphQL schema itself and you cannot modify as far as I can tell.
I want to know if I can use this as a subgraph in Apollo Federation. The reason I am unsure if it will work, is Apollo Federation appears to require metadata & directives to specify to the supergraph certain things (ie. the @keys directive on a type to say which fields are the Ids defined in both subgraphs). Because of stuff like this, and not seeing a way to add this to the GraphQL schema within the app service / Atlas GraphQL API, I don’t believe it would work.
But, in this article Building a Modern App Stack with Apollo GraphQL and MongoDB Atlas | MongoDB Blog I see that it is talking about Apollo supergraphs, and mentions the Atlas GraphQL API as 1 of 4 options, so it seems to imply it should be possible.
I realize that I could create my own service to handle GraphQL requests with Apollo Server or something similar, and hook it up to MongoDB as the datasource with something like Mongoose and therefore use it with Apollo Federation, but I am wondering if it is possible to use the Atlas GraphQL API as a subgraph for Apollo Federation.