-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathschema.gql
50 lines (43 loc) · 1.02 KB
/
schema.gql
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
# -----------------------------------------------
# !!! THIS FILE WAS GENERATED BY TYPE-GRAPHQL !!!
# !!! DO NOT MODIFY THIS FILE BY YOURSELF !!!
# -----------------------------------------------
type AccountEntity {
id: ID!
createdAt: Date!
updatedAt: Date!
email: String!
articles: [ArticleEntity!]!
}
input AddAccountInput {
email: String!
password: String!
}
input AddArticleInput {
title: String!
content: String!
accountId: ID!
}
type ArticleEntity {
id: ID!
createdAt: Date!
updatedAt: Date!
title: String!
content: String!
accountId: String!
account: AccountEntity!
}
"""Date custom scalar type"""
scalar Date
type Mutation {
addArticle(data: AddArticleInput!): ArticleEntity!
delArticle(id: String!): Boolean!
addAccount(data: AddAccountInput!): AccountEntity!
delAccount(id: String!): Boolean!
}
type Query {
article(id: String!): ArticleEntity!
articles(accountId: ID): [ArticleEntity!]!
account(id: String!): AccountEntity!
accounts(email: String): [AccountEntity!]!
}