How to Define an Input Union Type for File Uploads or Direct URLs in GraphQL Schema and Check Input Type in Resolver Mutation?
I’m working on a GraphQL schema where I need to allow users to upload files or provide direct URLs as input for an image field in a mutation. However, I’m facing difficulty defining an input type that can handle both file uploads and direct URLs, as well as checking the input type in the resolver mutation.