Support GraphQL schema federation

Is your feature request related to a problem? Please describe.
For an ongoing project, I need to implement an Apollo Gateway for a project, with a federated GraphQL schema from several sources, including DatoCMS.
Apollo provides those features already, it just requires the different GraphQL schemas to implement the Federation specifications:

I tried implementing a Gateway with DatoCMS as one of the federated source, but I do not think DatoCMS schema currently implements those specifications (unless I am doing something wrong?)

Encountered error when loading content at https://graphql.datocms.com/: Cannot read property ‘sdl’ of undefined

Describe the solution you’d like
Is it possible for DatoCMS to consider implementing those?
The migration from ApolloSever is pretty straightforward (not sure which tech is DatoCMS using under the hood but the @apollo/federation package can probably help, directly or as an example?)

Describe alternatives you’ve considered
An alternative would be to use DatoCMS as a Datasource for ApolloServer, but I am afraid to loose all the benefits of GraphQL by doing that?

Additional context
This is the local Gateway implementation I have tried (using node.js):

const { ApolloServer } = require('apollo-server');
const { ApolloGateway } = require('@apollo/gateway');

const gateway = new ApolloGateway({
  serviceList: [
    { name: 'my-service-1', url: 'http://localhost:4001' },
    { name: 'my-service-2', url: 'http://localhost:4002' },
    { name: 'content', url: 'https://graphql.datocms.com/' }
  ],
  buildService({ name, url }) {
    return new RemoteGraphQLDataSource({
      url,
      willSendRequest({ request, context }) {
        switch (name) {
          case 'content':
            // Authenticate requests to DatoCMS
            request.http.headers.set('authorization', process.env.DATOCMS_API_KEY);
            break;
        }
      },
    });
  },
  debug: process.env.NODE_ENV !== 'production'
});
  
(async () => {
  const { schema, executor } = await gateway.load();

  const server = new ApolloServer({ schema, executor });

  server.listen().then({ url }) => {
    console.log(`🚀 ApolloGateway ready at ${url}`);
  });
})();

A few more informations, it looks like the error is internally related to ApolloGateway not passing the authorization header to the introspection query.

Apollo is discussing how to do that at the moment, but after adding it for now, the error received is different:

const gateway = new ApolloGateway({
  // ...
  introspectionHeaders: {
    'authorization': process.env.DATOCMS_API_KEY
  },
  // ...
});

Field ‘_service’ doesn’t exist on type ‘Query’

I think the federation introspection query looks sort of:

query GetServiceDefinition {
  _service {
    sdl
  }
}

I also received the same error in Insomnia.
I believe it does confirm that DatoCMS at the moment does not implement those specifications?

I had the same issue. Vanilla GraphQL servers are not supported. You have to add federation support to the underlying service: https://www.apollographql.com/docs/apollo-server/federation/migrating-from-stitching/#adding-federation-support-to-services

I am going to have a look at using this soon. Hopefully it does what we need - perhaps you can try it too? https://github.com/0xR/graphql-transform-federation

I too am looking to do the exact same thing. Did you manage to get this working?
It would be so much easier if DatoCMS supported this rather than looking for a work around.