dgraph-io/dgraph · error
remote schema doesn't have any type named %s.
Error message
remote schema doesn't have any type named %s.
What it means
missingRemoteTypeError builds the standard error raised whenever a type name referenced during remote-schema validation (argument types, nested return types, expanded types) cannot be found in the introspected remote schema's type map. It is used by validateRemoteGraphql and matchArgSignature via expandType/matchDeepTypes.
Source
Thrown at graphql/schema/remote.go:348
if !metadata.isBatch {
// check whether args of given query/mutation match the args of remote query/mutation
err = matchArgSignature(&argMatchingMetadata{
givenArgVals: givenQryArgVals,
givenVarTypes: givenQryVarTypes,
remoteArgMd: remoteQryArgMetadata,
remoteTypes: remoteTypes,
givenQryName: &givenQuery.Name,
operationType: &operationType,
schema: metadata.schema,
})
}
return err
}
func missingRemoteTypeError(typName string) error {
return errors.Errorf("remote schema doesn't have any type named %s.", typName)
}
func matchDeepTypes(remoteType *gqlType, remoteTypes map[string]*types,
localSchema *ast.Schema) error {
_, err := expandType(remoteType, remoteTypes)
if err != nil {
return err
}
return matchRemoteTypes(localSchema, remoteTypes)
}
func matchRemoteTypes(schema *ast.Schema, remoteTypes map[string]*types) error {
for typeName, def := range schema.Types {
origTyp := schema.Types[typeName]
remoteDir := origTyp.Directives.ForName(remoteDirective)
if remoteDir != nil {
{
remoteType, ok := remoteTypes[def.Name]View on GitHub (pinned to 759e242be6)
Solutions
- Re-run introspection against the current remote endpoint and confirm the type exists in the schema.
- Update local config/SDL to stop referencing the removed/renamed remote type.
- If the type is defined but not introspected, check the remote server's introspection settings (e.g. disabled introspection or filtered SDL).
Example fix
// before
input UserFilter { role: UserRole }
// UserRole no longer exists remotely; after — use an existing remote type
input UserFilter { role: String } Defensive patterns
Strategy: validation
Validate before calling
const typeNames = new Set(introspection.__schema.types.map(t => t.name))
for (const ref of referencedTypes) if (!typeNames.has(ref)) throw new Error(`type ${ref} missing from remote schema`) Type guard
function remoteHasType(introspection, name) { return introspection?.__schema?.types?.some(t => t.name === name) ?? false } Prevention
- Re-introspect after every remote schema change and diff against referenced types
- Ensure remote introspection is enabled and returns all types
- Track remote API deprecations to anticipate type removals
When it happens
Trigger: During deep type matching, a named type referenced by a remote field's type or a remote argument is absent from remoteIntrospection.Data.Schema.Types, so remoteTypes[name] lookup fails and missingRemoteTypeError(name) is returned (graphql/schema/remote.go:348).
Common situations: Remote schema deprecated and removed a type still referenced locally; introspection result truncated (some servers omit builtin/scalar types); pointing at an older API version missing newly added types.
Related errors
- while json unmarshaling result from remote introspection que
- POST method cannot have query parameters in url: %s
- remote schema doesn't have any queries.
- remote schema doesn't have any mutations.
- %s `%s` is not present in remote schema.
AI-assisted analysis of dgraph-io/dgraph@759e242be6 (2026-09-01).
Data as JSON: /api/errors/1ba62778570044e2.
Report an issue: GitHub.