Skip to content

lfortin/freshplanet-test-1

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

freshplanet-test-1

GraphQL schema

  type Query {
    allForums: [Forum]
    joinedForumsByUserId(userId: ID = 0): [Forum]
    messagesByForumId(forumId: ID = 0, sortOrder: String = "DESC"): [Message]
    membersByForumId(forumId: ID = 0): [User]
  }

  type Mutation {
    createForum(userId: ID!, name: String!, description: String): CreateForumResponse
    joinForum(userId: ID!, forumId: ID!): JoinForumResponse
    postMessage(userId: ID!, forumId: ID!, content: String!): PostMessageResponse
  }

  type User {
    id: ID!
    firstName: String
    lastName: String
    picture: String
  }

  type Forum {
    id: ID!
    name: String
    description: String
  }

  type Message {
    id: ID!
    user: User
    forumId: ID!
    timestamp: Int
    content: String
  }

  type CreateForumResponse {
    statusText: String
    forum: Forum
  }

  type JoinForumResponse {
    statusText: String
  }
  
  type PostMessageResponse {
    statusText: String
    message: Message
  }

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published