-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathschema.graphql
77 lines (63 loc) · 1.87 KB
/
schema.graphql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
### This file was generated by Nexus Schema
### Do not make changes to this file directly
"""A blog article on the site"""
type Article {
slug: String!
stargazers(after: UserWhereUniqueInput, before: UserWhereUniqueInput, first: Int, last: Int): [User!]!
}
input ArticleCreateInput {
slug: String!
stargazers: UserCreateManyWithoutStarredArticlesInput
}
input ArticleWhereUniqueInput {
slug: String
}
scalar DateTime
type Mutation {
createOneArticle(data: ArticleCreateInput!): Article!
"""Star the given article for the current user"""
starArticle(
"""The slug of the article to star"""
slug: String!
): Article
"""Remove star for the given article for the current user"""
unstarArticle(
"""The slug of the article to unstar"""
slug: String!
): Article
}
type Query {
article(where: ArticleWhereUniqueInput!): Article
articles(after: ArticleWhereUniqueInput, before: ArticleWhereUniqueInput, first: Int, last: Int): [Article!]!
me: User
user(where: UserWhereUniqueInput!): User
users(after: UserWhereUniqueInput, before: UserWhereUniqueInput, first: Int, last: Int): [User!]!
}
"""A member of the club"""
type User {
id: Int!
image: String
name: String
starredArticles(after: ArticleWhereUniqueInput, before: ArticleWhereUniqueInput, first: Int, last: Int): [Article!]!
}
input UserCreateManyWithoutStarredArticlesInput {
connect: [UserWhereUniqueInput!]
connectOrCreate: [UserCreateOrConnectWithoutstarredArticlesInput!]
create: [UserCreateWithoutStarredArticlesInput!]
}
input UserCreateOrConnectWithoutstarredArticlesInput {
create: UserCreateWithoutStarredArticlesInput!
where: UserWhereUniqueInput!
}
input UserCreateWithoutStarredArticlesInput {
createdAt: DateTime
email: String
emailVerified: DateTime
image: String
name: String
updatedAt: DateTime
}
input UserWhereUniqueInput {
email: String
id: Int
}