{"size": 816, "ext": "js", "max_stars_repo_path": "server/schemas/typeDefs.js", "max_stars_repo_name": "samrobers/googleBooks", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "server/schemas/typeDefs.js", "max_issues_repo_name": "samrobers/googleBooks", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "server/schemas/typeDefs.js", "max_forks_repo_name": "samrobers/googleBooks", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 18.5454545455, "max_line_length": 70, "alphanum_fraction": 0.6029411765}
const { gql } = require("apollo-server-express");

const typeDefs = gql`
  type Profile {
    profileId: ID
    username: String!
    email: String!
    password: String!
    savedBooks: [Book]
  }

  type Book {
    _id: ID!
    bookId: String!
    authors: [String]
    description: String!
    image: String
    link: String
    title: String!
  }
  type Auth {
    token: ID!
    profile: Profile
  }
  type Query {
    profiles: [Profile]
  }
  type Mutation {
    saveBook(
      authors: [String]
      description: String
      bookId: String
      image: String
      link: String
      title: String
    ): Profile
    removeBook(_id: ID!): Profile
    logIn(email: String!, password: String!): Auth
    signUp(username: String!, email: String!, password: String!): Auth
  }
`;

module.exports = typeDefs;
