I saw in the GraphQL API Change Log that courses is being added on January 29, 2020. I can't find any details on what that involves, but perhaps there will be an assignmentsConnection then? There is already this inside allCourses so I hope it would be under the new courses as well.
It still wouldn't let you search by assignment name. When you try the nodes (name: "My Assignment"), you get a "Field 'nodes' doesn't accept argument 'name'" error message. Until that part is supported, you can get a list of all of the assignments and manually search through them.
You might be able to get a list of all assignments for all courses already. Note that this was a very long query for just the courses I'm enrolled in.
query allAssignmentsAllCourses {
allCourses {
_id
name
assignmentsConnection {
nodes {
_id
name
}
}
}
}
The issue is that allCourses returns just those courses that the user is enrolled in. The creative part would be creating a user that was enrolled in all of the courses that you needed to search. It could also be confusing to the instructor who wondered why there was an unknown person in their course.
Another approach is to use Canvas Data. It contains information about every assignment for every course, although the data is a little stale by the time you get it. Still, you would be able to get the assignment IDs quickly.