Commit ef6096ed authored by hdrury1's avatar hdrury1
Browse files

Update schema.graphqls

parent 535131ad
Pipeline #7224 failed with stages
in 3 minutes and 23 seconds
type Manuscript {
type Submission {
id: ID!
# Date type is not built in, need to import one
created: Date!
updated: Date!
# Can we abstract this out into ChangeLog?
stage: Stage!
title: String!
type: SubmissionType!
coverLetter: String!
"eLife 5 digit article ID which persists through to publication"
articleIdentifier: String
submissionIdentifier: String
subjectAreas: [MajorSubjectArea!]!
previouslyDiscussed: String
# should this be null or an empty array when there is no previously submitted data?
previouslySubmitted: [ArticleSearchParameters!]
coSubmission: [ArticleSearchParameters!]
relatedArticles: [RelatedArticle!]!
previouslySubmitted: [SubmissionSearchParameters!]
coSubmission: [SubmissionSearchParameters!]
relatedSubmission: [RelatedSubmission!]
suggestedEditors: [EditorSuggestion!]!
excludedEditors: [EditorSuggestion!]!
suggestedReviewers: [ReviewerSuggestion!]!
excludedReviewers: [ReviewerSuggestion!]!
# is this name too long?
declarationOfNoConflictOfInterest: Boolean!
suggestionsConflict: Boolean!
persons: [ManuscriptPerson!]!
qcIssues: [QCIssue!]!
submissionFiles: [Files!]!
submissionHistory: [ChangeLog!]
# How to name stages?
......@@ -35,6 +38,14 @@ enum Stage {
enum SubmissionType {
Research Article
Tools and Resources
Short Report
Research Advance
# How often do these change? Should they be queried from the elife API at runtime or embedded in the app?
enum MajorSubjectArea {
......@@ -43,24 +54,35 @@ enum MajorSubjectArea {
type ArticleSearchParameters {
type SubmissionSearchParameters {
title: String!
author: String!
corrAuthor: String!
# Is is weird that this type has only one required field?
type ManuscriptPerson {
user: User
role: ManuscriptRole!
# should alias actually be part of AuthorMetadata? It's only ever present for authors.
# does the alias data have any use once the author is resolved to a user?
alias: AuthorAlias
metadata: ManuscriptPersonMetadata
type AuthorAlias {
# this extends the base type in pubsweet
extend type User {
first name: String!
last name: String!
published name: String
institution: String!
email: String!
orcidId: String!
roles: [GlobalRole!]!
type UserAlias {
firstName: String!
lastName: String!
publishedName: String
email: String!
# Is this free text? The institution we get back from ORCID is disambiguated
# but we lose that information if the author edits the field
......@@ -72,17 +94,17 @@ interface ManuscriptPersonMetadata
type AuthorMetadata implements ManuscriptPersonMetatdata {
rank: Int!
contributions: AuthorMetadataContribution!
coRelationship: ManuscriptPerson
contributions: String
corresponding: Boolean!
conflictOfInterest: String
type ReviewerMetadata implements ManuscriptPersonMetatdata {
# is rank always present?
rank: Int
rank: Int!
coRelationship: ManuscriptPerson
conflictOfInterest: String
revealIdentity: Boolean
revealIdentity: Boolean!
enum ManuscriptRole {
......@@ -91,11 +113,7 @@ enum ManuscriptRole {
# The following two would have the same permissions as an Author but are
# used for distinguishing the type of their relationship to the manuscript.
# Is this mixing responsibilities? Would it be better to model this as data on AuthorMetadata?
type EditorSuggestion {
......@@ -107,28 +125,30 @@ type EditorSuggestion {
type ReviewerSuggestion {
name: String!
email: String!
role: ManuscriptRole!
reason: String
type ChangeLog {
id: ID!
created: Date!
# would all logged changes relate to a manuscript?
manuscript: Manuscript
manuscript: Submission!
user: User
actions: [Action!]!
# to be defined
type Action
type Action {
type File {
# what is the URI? a path on the server? a file in an S3 bucket? a public URL?
uri: String!
type: FileType!
# MIME type
fileType: String!
format: String!
size: String!
lastChangeDate: Date!
lastChangeUser: User!
# what is the file type used for? What do we need to distinguish?
......@@ -139,25 +159,17 @@ enum FileType {
type RelatedArticle {
type: ArticleRelationship!
articleIdentifier: String!
type RelatedSubmission {
connectionType: SubmissionRelationship!
submissionIdentifier: String!
Title: String!
# what are the possible types of relationship? Same as JATS?
enum ArticleRelationship
type ArticleSearchParameters {
title: String!
correspondingAuthor: String!
# Do we need in addition to 'manuscript.relatedArticles'?
matchedRelation: RelatedArticle
# this extends the base type in pubsweet
extend type User {
orcidId: String!
roles: [GlobalRole!]!
enum SubmissionRelationship {
enum GlobalRole {
......@@ -167,16 +179,17 @@ enum GlobalRole {
# One role encompasses the permissions etc. of the role(s) below it. Senior editor has all permissions of Reviewing editor and appears in lists of reviewing editors
type QCIssue {
id: ID!
created: Date!
manuscript: Manuscript!
location: String!
submission: Submission!
location: QCIssueLocation!
#to be defined
comments: [Comment!]!
type: String!
resolved: Boolean
resolved: Boolean!
type Comment {
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment