1717except ImportError : # Python < 3.10
1818 from typing_extensions import TypeAlias
1919
20-
2120__all__ = [
2221 "IntrospectionDirective" ,
2322 "IntrospectionEnumType" ,
@@ -44,6 +43,7 @@ def get_introspection_query(
4443 directive_is_repeatable : bool = False ,
4544 schema_description : bool = False ,
4645 input_value_deprecation : bool = False ,
46+ input_object_one_of : bool = False ,
4747) -> str :
4848 """Get a query for introspection.
4949
@@ -55,6 +55,7 @@ def get_introspection_query(
5555 maybe_specified_by_url = "specifiedByURL" if specified_by_url else ""
5656 maybe_directive_is_repeatable = "isRepeatable" if directive_is_repeatable else ""
5757 maybe_schema_description = maybe_description if schema_description else ""
58+ maybe_input_object_one_of = "isOneOf" if input_object_one_of else ""
5859
5960 def input_deprecation (string : str ) -> str | None :
6061 return string if input_value_deprecation else ""
@@ -87,6 +88,7 @@ def input_deprecation(string: str) -> str | None:
8788 name
8889 { maybe_description }
8990 { maybe_specified_by_url }
91+ { maybe_input_object_one_of }
9092 fields(includeDeprecated: true) {{
9193 name
9294 { maybe_description }
@@ -253,6 +255,7 @@ class IntrospectionEnumType(WithName):
253255class IntrospectionInputObjectType (WithName ):
254256 kind : Literal ["input_object" ]
255257 inputFields : list [IntrospectionInputValue ]
258+ isOneOf : bool
256259
257260
258261IntrospectionType : TypeAlias = Union [
@@ -264,7 +267,6 @@ class IntrospectionInputObjectType(WithName):
264267 IntrospectionInputObjectType ,
265268]
266269
267-
268270IntrospectionOutputType : TypeAlias = Union [
269271 IntrospectionScalarType ,
270272 IntrospectionObjectType ,
@@ -273,7 +275,6 @@ class IntrospectionInputObjectType(WithName):
273275 IntrospectionEnumType ,
274276]
275277
276-
277278IntrospectionInputType : TypeAlias = Union [
278279 IntrospectionScalarType , IntrospectionEnumType , IntrospectionInputObjectType
279280]
0 commit comments