fix-graphql
This commit is contained in:
commit
0c296ac494
|
@ -2,8 +2,8 @@ import { ClientOptions, dedupExchange, fetchExchange, createClient, Exchange } f
|
||||||
import { devtoolsExchange } from '@urql/devtools'
|
import { devtoolsExchange } from '@urql/devtools'
|
||||||
import { isDev } from '../utils/config'
|
import { isDev } from '../utils/config'
|
||||||
|
|
||||||
//export const baseUrl = 'https://newapi.discours.io'
|
export const baseUrl = 'https://newapi.discours.io'
|
||||||
export const baseUrl = 'http://localhost:8000'
|
// export const baseUrl = 'http://localhost:8000'
|
||||||
|
|
||||||
const exchanges: Exchange[] = [dedupExchange, fetchExchange]
|
const exchanges: Exchange[] = [dedupExchange, fetchExchange]
|
||||||
|
|
||||||
|
|
|
@ -32,9 +32,22 @@ export type Author = {
|
||||||
|
|
||||||
export type Chat = {
|
export type Chat = {
|
||||||
createdAt: Scalars['DateTime']
|
createdAt: Scalars['DateTime']
|
||||||
|
createdBy: User
|
||||||
description?: Maybe<Scalars['String']>
|
description?: Maybe<Scalars['String']>
|
||||||
id: Scalars['Int']
|
id: Scalars['Int']
|
||||||
|
messages?: Maybe<Array<Maybe<Message>>>
|
||||||
|
title?: Maybe<Scalars['String']>
|
||||||
updatedAt: Scalars['DateTime']
|
updatedAt: Scalars['DateTime']
|
||||||
|
users: Array<Maybe<User>>
|
||||||
|
}
|
||||||
|
|
||||||
|
export type ChatResult = {
|
||||||
|
createdAt: Scalars['DateTime']
|
||||||
|
createdBy?: Maybe<User>
|
||||||
|
error?: Maybe<Scalars['String']>
|
||||||
|
members: Array<Maybe<User>>
|
||||||
|
messages?: Maybe<Array<Maybe<Message>>>
|
||||||
|
title?: Maybe<Scalars['String']>
|
||||||
}
|
}
|
||||||
|
|
||||||
export type ChatUpdatedResult = {
|
export type ChatUpdatedResult = {
|
||||||
|
@ -140,10 +153,11 @@ export type Mutation = {
|
||||||
follow: Result
|
follow: Result
|
||||||
incrementView: Result
|
incrementView: Result
|
||||||
inviteAuthor: Result
|
inviteAuthor: Result
|
||||||
|
inviteChat: Result
|
||||||
markAsRead: Result
|
markAsRead: Result
|
||||||
rateUser: Result
|
rateUser: Result
|
||||||
refreshSession: AuthResult
|
refreshSession: AuthResult
|
||||||
registerUser: AuthResult
|
registerUser: User
|
||||||
removeAuthor: Result
|
removeAuthor: Result
|
||||||
sendLink: Result
|
sendLink: Result
|
||||||
unfollow: Result
|
unfollow: Result
|
||||||
|
@ -229,6 +243,11 @@ export type MutationInviteAuthorArgs = {
|
||||||
shout: Scalars['String']
|
shout: Scalars['String']
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export type MutationInviteChatArgs = {
|
||||||
|
chatId: Scalars['String']
|
||||||
|
userslug: Scalars['String']
|
||||||
|
}
|
||||||
|
|
||||||
export type MutationMarkAsReadArgs = {
|
export type MutationMarkAsReadArgs = {
|
||||||
chatId: Scalars['String']
|
chatId: Scalars['String']
|
||||||
ids: Array<InputMaybe<Scalars['Int']>>
|
ids: Array<InputMaybe<Scalars['Int']>>
|
||||||
|
@ -315,16 +334,17 @@ export type ProfileInput = {
|
||||||
export type Query = {
|
export type Query = {
|
||||||
authorsAll: Array<Maybe<User>>
|
authorsAll: Array<Maybe<User>>
|
||||||
collectionsAll: Array<Maybe<Collection>>
|
collectionsAll: Array<Maybe<Collection>>
|
||||||
enterChat: EnterChatResult
|
enterChat: ChatResult
|
||||||
getCollabs: Array<Maybe<Collab>>
|
getCollabs: Array<Maybe<Collab>>
|
||||||
getCommunities: Array<Maybe<Community>>
|
getCommunities: Array<Maybe<Community>>
|
||||||
getCommunity: Community
|
getCommunity: Community
|
||||||
getMessages: Array<Maybe<Message>>
|
|
||||||
getShoutBySlug: Shout
|
getShoutBySlug: Shout
|
||||||
getUserCollections: Array<Maybe<Collection>>
|
getUserCollections: Array<Maybe<Collection>>
|
||||||
getUserRoles: Array<Maybe<Role>>
|
getUserRoles: Array<Maybe<Role>>
|
||||||
getUsersBySlugs: Array<Maybe<User>>
|
getUsersBySlugs: Array<Maybe<User>>
|
||||||
isEmailUsed: Scalars['Boolean']
|
isEmailUsed: Scalars['Boolean']
|
||||||
|
loadChat: Array<Maybe<Message>>
|
||||||
|
myChats: Array<Maybe<ChatResult>>
|
||||||
reactionsByAuthor: Array<Maybe<Reaction>>
|
reactionsByAuthor: Array<Maybe<Reaction>>
|
||||||
reactionsByShout: Array<Maybe<Reaction>>
|
reactionsByShout: Array<Maybe<Reaction>>
|
||||||
reactionsForShouts: Array<Maybe<Reaction>>
|
reactionsForShouts: Array<Maybe<Reaction>>
|
||||||
|
@ -350,7 +370,6 @@ export type Query = {
|
||||||
topicsByAuthor: Array<Maybe<Topic>>
|
topicsByAuthor: Array<Maybe<Topic>>
|
||||||
topicsByCommunity: Array<Maybe<Topic>>
|
topicsByCommunity: Array<Maybe<Topic>>
|
||||||
topicsRandom: Array<Maybe<Topic>>
|
topicsRandom: Array<Maybe<Topic>>
|
||||||
userChats: UserChatsResult
|
|
||||||
userFollowedAuthors: Array<Maybe<User>>
|
userFollowedAuthors: Array<Maybe<User>>
|
||||||
userFollowedCommunities: Array<Maybe<Community>>
|
userFollowedCommunities: Array<Maybe<Community>>
|
||||||
userFollowedTopics: Array<Maybe<Topic>>
|
userFollowedTopics: Array<Maybe<Topic>>
|
||||||
|
@ -358,26 +377,14 @@ export type Query = {
|
||||||
userReactedShouts: Array<Maybe<Shout>>
|
userReactedShouts: Array<Maybe<Shout>>
|
||||||
}
|
}
|
||||||
|
|
||||||
export type QueryAuthorsAllArgs = {
|
|
||||||
limit: Scalars['Int']
|
|
||||||
offset: Scalars['Int']
|
|
||||||
}
|
|
||||||
|
|
||||||
export type QueryEnterChatArgs = {
|
export type QueryEnterChatArgs = {
|
||||||
chatId: Scalars['String']
|
chatId: Scalars['String']
|
||||||
size?: InputMaybe<Scalars['Int']>
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export type QueryGetCommunityArgs = {
|
export type QueryGetCommunityArgs = {
|
||||||
slug?: InputMaybe<Scalars['String']>
|
slug?: InputMaybe<Scalars['String']>
|
||||||
}
|
}
|
||||||
|
|
||||||
export type QueryGetMessagesArgs = {
|
|
||||||
chatId: Scalars['String']
|
|
||||||
page: Scalars['Int']
|
|
||||||
size: Scalars['Int']
|
|
||||||
}
|
|
||||||
|
|
||||||
export type QueryGetShoutBySlugArgs = {
|
export type QueryGetShoutBySlugArgs = {
|
||||||
slug: Scalars['String']
|
slug: Scalars['String']
|
||||||
}
|
}
|
||||||
|
@ -398,6 +405,12 @@ export type QueryIsEmailUsedArgs = {
|
||||||
email: Scalars['String']
|
email: Scalars['String']
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export type QueryLoadChatArgs = {
|
||||||
|
chatId: Scalars['String']
|
||||||
|
page: Scalars['Int']
|
||||||
|
size: Scalars['Int']
|
||||||
|
}
|
||||||
|
|
||||||
export type QueryReactionsByAuthorArgs = {
|
export type QueryReactionsByAuthorArgs = {
|
||||||
limit: Scalars['Int']
|
limit: Scalars['Int']
|
||||||
offset: Scalars['Int']
|
offset: Scalars['Int']
|
||||||
|
@ -476,7 +489,7 @@ export type QueryShoutsForFeedArgs = {
|
||||||
offset: Scalars['Int']
|
offset: Scalars['Int']
|
||||||
}
|
}
|
||||||
|
|
||||||
export type MutationSignInArgs = {
|
export type QuerySignInArgs = {
|
||||||
email: Scalars['String']
|
email: Scalars['String']
|
||||||
password?: InputMaybe<Scalars['String']>
|
password?: InputMaybe<Scalars['String']>
|
||||||
}
|
}
|
||||||
|
@ -760,11 +773,6 @@ export type User = {
|
||||||
wasOnlineAt?: Maybe<Scalars['DateTime']>
|
wasOnlineAt?: Maybe<Scalars['DateTime']>
|
||||||
}
|
}
|
||||||
|
|
||||||
export type UserChatsResult = {
|
|
||||||
chats?: Maybe<Array<Maybe<Scalars['String']>>>
|
|
||||||
error?: Maybe<Scalars['String']>
|
|
||||||
}
|
|
||||||
|
|
||||||
export type UserNotification = {
|
export type UserNotification = {
|
||||||
id: Scalars['Int']
|
id: Scalars['Int']
|
||||||
kind: Scalars['String']
|
kind: Scalars['String']
|
||||||
|
|
Loading…
Reference in New Issue
Block a user