82 lines
1.9 KiB
JavaScript
Raw Normal View History

2021-03-25 14:29:24 -05:00
import { gql } from 'apollo-server-micro'
export default gql`
extend type Query {
me: User
2022-06-02 17:55:23 -05:00
settings: User
2021-05-21 17:32:21 -05:00
user(name: String!): User
2021-03-25 14:29:24 -05:00
users: [User!]
2021-05-21 17:32:21 -05:00
nameAvailable(name: String!): Boolean!
2022-02-02 15:50:12 -06:00
topUsers(cursor: String, within: String!, userType: String!): TopUsers
2022-08-26 17:20:09 -05:00
searchUsers(name: String!): [User!]!
2021-12-16 18:01:02 -06:00
}
type Users {
cursor: String
users: [User!]!
2021-03-25 14:29:24 -05:00
}
2022-02-02 15:50:12 -06:00
type TopUsers {
cursor: String
users: [TopUser!]!
}
type TopUser {
name: String!
createdAt: String!
amount: Int!
}
2021-05-21 19:09:11 -05:00
extend type Mutation {
setName(name: String!): Boolean
2022-04-21 17:50:02 -05:00
setSettings(tipDefault: Int!, noteItemSats: Boolean!, noteEarning: Boolean!,
noteAllDescendants: Boolean!, noteMentions: Boolean!, noteDeposits: Boolean!,
2022-09-27 16:19:15 -05:00
noteInvites: Boolean!, noteJobIndicator: Boolean!, hideInvoiceDesc: Boolean!,
wildWestMode: Boolean!, greeterMode: Boolean!): User
2022-05-16 15:51:22 -05:00
setPhoto(photoId: ID!): Int!
2021-09-24 16:28:21 -05:00
upsertBio(bio: String!): User!
2021-12-09 14:40:40 -06:00
setWalkthrough(tipPopover: Boolean, upvotePopover: Boolean): Boolean
2022-06-02 17:55:23 -05:00
unlinkAuth(authType: String!): AuthMethods!
linkUnverifiedEmail(email: String!): Boolean
}
type AuthMethods {
lightning: Boolean!
email: String
twitter: Boolean!
github: Boolean!
2021-05-21 19:09:11 -05:00
}
2021-03-25 14:29:24 -05:00
type User {
id: ID!
2021-09-24 16:28:21 -05:00
createdAt: String!
2021-03-25 14:29:24 -05:00
name: String
2021-04-22 17:14:32 -05:00
nitems: Int!
ncomments: Int!
stacked: Int!
2021-05-24 19:08:56 -05:00
freePosts: Int!
freeComments: Int!
2021-06-24 18:56:01 -05:00
hasNewNotes: Boolean!
2021-10-15 18:07:51 -05:00
hasInvites: Boolean!
2021-09-12 11:55:38 -05:00
tipDefault: Int!
2021-09-23 12:42:00 -05:00
bio: Item
2022-04-28 13:11:05 -05:00
bioId: Int
2022-05-16 15:51:22 -05:00
photoId: Int
2021-04-22 17:14:32 -05:00
sats: Int!
2021-12-09 14:40:40 -06:00
upvotePopover: Boolean!
tipPopover: Boolean!
2022-04-21 17:50:02 -05:00
noteItemSats: Boolean!
noteEarning: Boolean!
noteAllDescendants: Boolean!
noteMentions: Boolean!
noteDeposits: Boolean!
noteInvites: Boolean!
noteJobIndicator: Boolean!
2022-08-30 16:50:47 -05:00
hideInvoiceDesc: Boolean!
2022-09-21 14:57:36 -05:00
wildWestMode: Boolean!
2022-09-27 16:19:15 -05:00
greeterMode: Boolean!
lastCheckedJobs: String
2022-06-02 17:55:23 -05:00
authMethods: AuthMethods!
2021-03-25 14:29:24 -05:00
}
`