# Philosophers API GraphQL Schema # Endpoint: POST https://philosophersapi.com/graphql type Query { """Query for all AR objects""" allARObjects: [ARObjectDetailsResponse!]! """Query for all categories""" allCategories: [CategoryDetailsResponse!]! """Query for all key ideas""" allKeyIdeas: [KeyIdeaWithPhilosopher!]! """Query for all philosophers""" allPhilosophers: [PhilosopherResponse!]! """Query for all quotes""" allQuotes: [PhilosopherQuoteResponse!]! """Query for an AR object by ID""" arObject(idString: String!): ARObjectDetailsResponse """Query for AR objects by name""" arObjectByName(name: String!): ARObjectDetailsResponse! """Query for a category by ID""" category(idString: String!): CategoryDetailsResponse """Query for categories by name""" categoryByName(name: String!): CategoryDetailsResponse! """Get philosophers in a collection ordered by sort""" collectionPhilosophers(collectionID: String!): [PhilosopherResponse!]! """Get quotes in a collection ordered by sort""" collectionQuotes(collectionID: String!): [PhilosopherQuoteResponse!]! """Explain a philosophical passage in plain English and link related Key Ideas""" explainPassage(passage: String!, philosopherName: String, workTitle: String, keyIdeaLines: [String!], provider: String): PassageExplanation! """Query for a key idea by ID""" keyIdea(idString: String!): KeyIdeaDetailsResponse """Query for key ideas by IDs""" keyIdeas(ids: [String!]!): [KeyIdeaDetailsResponse!]! """Query for the currently authenticated user""" me: UserResponse """Query for a philosopher by ID""" philosopher(idString: String!): PhilosopherResponse! """Query for philosophers by audiobook ID""" philosopherByAudiobookID(idString: String!): PhilosopherWithAudiobook! """Query for philosophers by name""" philosopherByName(name: String!): PhilosopherResponse! """Query for philosophers by name""" philosopherByUsername(name: String!): PhilosopherResponse! """Query for philosophers by IDs""" philosophers(ids: [String!]!): [PhilosopherResponse!]! """Rewrite a sentence in the style of each requested philosopher""" philosophize(text: String!, philosopherNames: [String!]!, provider: String): [PhilosophizedText!]! """Query for a quote by ID""" quote(idString: String!): PhilosopherQuoteResponse """Query for quotes by IDs""" quotes(ids: [String!]!): [PhilosopherQuoteResponse!]! """Query for quotes for a philosopher by ID""" quotesForPhilosopher(idString: String!): [PhilosopherQuoteResponse!] """Query for random key ideas""" randomKeyIdeas(count: Int!): [KeyIdeaDetailsResponse!]! """Query for random philosophers""" randomPhilosophers(count: Int!): [PhilosopherResponse!]! """Query for random quotes""" randomQuotes(count: Int!): [PhilosopherQuoteResponse!]! """Generate an in-character reply from a philosopher inside a quote thread""" replyToQuoteThread(philosopherName: String!, quote: String!, work: String, userMessage: String!, history: [ThreadMessageInput!], provider: String): PhilosophizedText! """Query for categories by search term""" searchCategories(search: String!): [CategoryDetailsResponse!]! """Query for key ideas by search term""" searchKeyIdeas(search: String!): [KeyIdeaDetailsResponse!]! """Query for philosophers by search term""" searchPhilosophers(search: String!): [PhilosopherResponse!]! """Query for quotes by search term""" searchQuotes(search: String!): [PhilosopherQuoteResponse!]! """Stage an alternating philosophical dialogue between two philosophers""" symposium(question: String!, philosopherNames: [String!]!, turns: Int, provider: String): [PhilosophizedText!]! } type Mutation { """Add a philosopher to a collection""" addPhilosopherToCollection(collectionID: String!, philosopherID: String!): Boolean! """Add a quote to a collection""" addQuoteToCollection(collectionID: String!, quoteID: String!): Boolean! """Complete user login""" completeLogin(challenge: String!, assertion: String!): LoginSuccess! """Complete user registration""" completeRegistration(challenge: String!, publicKey: String!): RegistrationSuccess! """Favorite a philosopher""" favoritePhilosopher(id: String!, sortOrder: Int): Boolean! """Favorite a quote""" favoriteQuote(id: String!, sortOrder: Int): Boolean! """Start the login process for a user""" loginUser(username: String!): ChallengeResponse! """Move a philosopher within a collection""" movePhilosopherInCollection(collectionID: String!, philosopherID: String!, index: Int!): Boolean! """Move a quote within a collection""" moveQuoteInCollection(collectionID: String!, quoteID: String!, index: Int!): Boolean! """Start the registration process for a new user""" registerUser(name: String!, username: String!, email: String!): ChallengeResponse! """Remove a philosopher from a collection""" removePhilosopherFromCollection(collectionID: String!, philosopherID: String!): Boolean! """Remove a quote from a collection""" removeQuoteFromCollection(collectionID: String!, quoteID: String!): Boolean! """Replace philosophers in a collection""" setPhilosophersInCollection(collectionID: String!, philosopherIDs: [String!]!): Boolean! """Replace quotes in a collection""" setQuotesInCollection(collectionID: String!, quoteIDs: [String!]!): Boolean! """Remove a philosopher from favorites""" unfavoritePhilosopher(id: String!): Boolean! """Remove a quote from favorites""" unfavoriteQuote(id: String!): Boolean! } """A response containing information about an AR object""" type ARObjectDetailsResponse { """The AR file path for the AR object""" arFile: String! """A description of the AR object""" description: String """The UUID of the AR object""" id: String """The name of the AR object""" name: String! """The original title of the AR object""" originalTitle: String """The philosopher that is associated with the AR object""" philosopher: PhilosopherResponse! """The URL of the AR object's store page""" storeURL: String """Object that holds paths to the images of the AR Object""" thumbnailImages: ARObjectImages! """The type of the AR object""" type: ARObjectType! """The title Wikipedia article about the subject of the AR Object""" wikiTitle: String } """Object that holds paths to the images of an AR Object""" type ARObjectImages { """The path to the 150x150 thumbnail of the object""" thumbnail150x150: String! """The path to the 300x300 thumbnail of the object""" thumbnail300x300: String! """The path to the 450x450 thumbnail of the object""" thumbnail450x450: String! } """Object that represents an AR Object""" type ARObjectResponse { """The path to the AR file of the AR Object""" arFile: String! """A description of the AR Object""" description: String """The UUID of the AR Object""" id: String """The name of the AR Object""" name: String! """The original title of the AR Object if it's a book""" originalTitle: String """The UUID of the philosopher associated with the AR Object""" philosopherID: String! """The URL to where the AR Object can be purchased if it's a book""" storeURL: String """Object that holds paths to the images of the AR Object""" thumbnailImages: ARObjectImages! """The type of the AR Object""" type: ARObjectType! """The title Wikipedia article about the subject of the AR Object""" wikiTitle: String } """Enum that represents the type of an AR Object""" enum ARObjectType { """AR Object is a book""" book """AR Object is an object""" object """AR Object is a statue""" statue } """A response containing information about a category""" type CategoryDetailsResponse { """The abbreviation of the category""" abbreviation: String! """An array of philosophers associated with the category""" associatedPhilosophers: [PhilosopherResponse!]! """A description of the category""" description: String! """The unique identifier for the category""" id: String """The link to the category's Internet Encyclopedia of Philosophy page""" iepLink: String """An object for images of the category""" images: CategoryImages! """The name of the category""" name: String! """The link to the category's Stanford Encyclopedia of Philosophy page""" speLink: String """The title of the category's Wikipedia page""" wikiTitle: String! } """An object with paths to images of a category""" type CategoryImages { """A 1200x900 banner alpha-channel image for the category""" banner1200x900: String! """A 400x300 banner alpha-channel image for the category""" banner400x300: String! """A 800x600 banner alpha-channel image for the category""" banner800x600: String! } """A challenge used in the WebAuthn flow""" type ChallengeResponse { """Base64 encoded challenge string""" challenge: String! } """Object with paths to face images of the philosopher""" type FaceImages { """A 250x250px face image of the philosopher""" face250x250: String! """A 500x500px face image of the philosopher""" face500x500: String! """A 750x750px face image of the philosopher""" face750x750: String! } """Object with paths to full images of the philosopher""" type FullImages { """A 1200x1600px full image of the philosopher""" full1200x1600: String! """A 1260x1680px full image of the philosopher""" full1260x1680: String! """A 420x560px full image of the philosopher""" full420x560: String! """A 600x800px full image of the philosopher""" full600x800: String! """A 840x1120px full image of the philosopher""" full840x1120: String! } """Object that describes a Gutenberg author""" type GutenbergAuthor { """The year the author was born""" birthYear: Int """The year the author died""" deathYear: Int """The name of the author""" name: String! } """Object that represents a Gutenberg book""" type GutenbergBook { """The authors of the book""" authors: [GutenbergAuthor!]! """The bookshelves the book belongs to""" bookshelves: [String!]! """Whether the book is copyrighted""" copyright: Boolean! """The formats of the book""" formats: GutenbergFormats! """The ID of the book""" id: Int! """The languages of the book""" languages: [String!]! """The media type of the book""" mediaType: String! """How the book stands to the philosopher: work, collection (with others' writing) or about""" relation: String """The multivolume set the book is a volume of""" series: String """The subjects of the book""" subjects: [String!]! """The title of the book""" title: String! """The book's place in its series""" volume: Int """When the work was first published, or written; negative for BCE""" year: Int } """Object with information about the formats of a Gutenberg book""" type GutenbergFormats { """The URL of the EPUB zip file""" epubZip: String """The URL of the HTML file""" html: String """The URL of the book's full-size cover""" image: String """The URL of the Mobi file""" mobi: String """The URL of the plain text file""" plainText: String """The URL of the plain text ISO file""" plainTextISO: String """The URL of the plain text UTF-8 file""" plainTextUTF8: String """The URL of the RDF file""" rdf: String """The URL of a 600px-wide copy of the book's cover""" thumbnail: String """The URL of the zip file""" zip: String } """Object with paths to large illustrations of the philosopher""" type IllustrationImages { """A 250x250px illustration of the philosopher""" ill250x250: String! """A 500x500px illustration of the philosopher""" ill500x500: String! """A 750x750px illustration of the philosopher""" ill750x750: String! } """Object with information about a key idea""" type KeyIdea { """An array of abbreviations for the categories of the key idea""" categoryAbbrevs: [String!]! """The UUID of the key idea""" id: String """The UUID of the philosopher that the key idea is from""" philosopherId: String """Citation for the key idea""" reference: String! """Summary of a key idea of the philosopher""" text: String! } """A response containing information about a key idea""" type KeyIdeaDetailsResponse { """Key Ideas that largely agree with the key idea""" agreeingKeyIdeas: [KeyIdeaWithPhilosopher!] """An array of abbreviations for the categories of the key idea""" categoryAbbrevs: [String!]! """Key Ideas that largely disagree with the key idea""" disagreeingKeyIdeas: [KeyIdeaWithPhilosopher!] """The UUID of the key idea""" id: String """The philosopher that the key idea is from""" philosopher: PhilosopherResponse! """Citation for the key idea""" reference: String! """Summary of a key idea of the philosopher""" text: String! } """A response containing information about a key idea and its associated philosopher""" type KeyIdeaWithPhilosopher { """An array of abbreviations for the categories of the key idea""" categoryAbbrevs: [String!]! """The UUID of the key idea""" id: String """The philosopher that the key idea is from""" philosopher: PhilosopherResponse! """Citation for the key idea""" reference: String! """Summary of a key idea of the philosopher""" text: String! } """Object that represents a LibriVox author""" type LibriVoxAuthor { dateOfBirth: String dateOfDeath: String firstName: String id: String! lastName: String } """Object that represents a LibriVox book""" type LibriVoxBook { authors: [LibriVoxAuthor!] copyrightYear: String description: String genres: [LibriVoxGenre!] gutenbergTexts: [LibriVoxText!]! id: String! language: String numberOfSections: String """How the recording stands to the philosopher: work, collection (with others' writing) or about""" relation: String sections: [LibriVoxSection!] """The work this recording is one part of, when it's recorded in parts""" series: String title: String! totalTime: String totalTimeSecs: Float! translators: [LibriVoxTranslator!] urlInternetArchive: String urlLibrivox: String urlOther: String urlProject: String urlRSS: String urlTextSource: String urlZipFile: String """The Project Gutenberg texts this recording reads, checked against the recording; empty when unknown""" volume: Int """When the work was first published, or written; negative for BCE""" year: Int } """Object that represents a LibriVox genre""" type LibriVoxGenre { id: String! name: String } """Object that represents a LibriVox reader""" type LibriVoxReader { displayName: String readerID: String } """Object that represents a LibriVox section""" type LibriVoxSection { fileName: String id: String! language: String listenURL: String playtime: String readers: [LibriVoxReader!] sectionNumber: String! title: String } """A Project Gutenberg text a LibriVox recording reads, from its firstSection (numbered from 1) on""" type LibriVoxText { firstSection: Int! gutenbergID: Int! } """Object that represents a LibriVox translator""" type LibriVoxTranslator { dateOfBirth: String dateOfDeath: String firstName: String id: String! lastName: String } type LoginSuccess { """ID of the logged in user""" id: String! } """A plain-English explanation of a philosophical passage""" type PassageExplanation { """Difficult terms from the passage explained in context""" keyTerms: [PassageTerm!]! """A clear plain-English unpacking of the passage""" plainEnglish: String! """Zero-based indices into keyIdeaLines that relate to the passage""" relatedIdeaIndices: [Int!]! """A one-sentence plain-English takeaway of the passage""" summary: String! } """A defined philosophical term from an explained passage""" type PassageTerm { """A concise plain-English explanation of the term in context""" explanation: String! """A technical or specialized term from the passage""" term: String! } """Object with objects of paths to images of the philosopher""" type PhilosopherImages { """An object with the relative location of the face images of the philosopher""" faceImages: FaceImages! """An object with the relative location of the full images of the philosopher""" fullImages: FullImages! """An object with the relative location of the illustrations of the philosopher""" illustrations: IllustrationImages! """An object with the relative location of the thumbnail illustrations of the philosopher""" thumbnailIllustrations: SmallIllustrationImages! } """Object with information about the location where the philosopher was born""" type PhilosopherLocation { """The latitude of the location where the philosopher was born""" latitude: Float! """The longitude of the location where the philosopher was born""" longitude: Float! """The name of the location where the philosopher was born""" name: String! } """A response containing information about a quote and its associated philosopher and related quotes""" type PhilosopherQuoteResponse { """The unique identifier for the quote""" id: String """The philosopher who wrote the quote""" philosopher: PhilosopherResponse! """The quote text""" quote: String! """An array of related quotes""" relatedQuotes: [QuoteWithPhilosopher!] """The work the quote was written in""" work: String """The year the quote was written""" year: String } """A response containing information about a philosopher""" type PhilosopherResponse { """An array of AR objects for the philosopher""" arObjects: [ARObjectResponse!]! """The date the philosopher was born""" birthDate: String """The location of the philosopher's birth""" birthLocation: PhilosopherLocation """The year the philosopher was born""" birthYear: String! """The date the philosopher died""" deathDate: String """The year the philosopher died""" deathYear: String """An array of project gutenberg e-books by/about the philosopher""" ebooks: [GutenbergBook!]! """A boolean indicating whether the philosopher has e-books available""" hasEBooks: Boolean! """The UUID of the philosopher""" id: String """A link to the Internet Encyclopedia of Philosophy page for the philosopher""" iepLink: String """An object for images of the philosopher""" images: PhilosopherImages! """The philosophical interests of the philosopher""" interests: String! """An array of key ideas by the philosopher""" keyIdeas: [KeyIdea!]! """An array of audio books available for the philosopher""" libriVoxBooks: [LibriVoxBook!]! """An array of links to get metadata about audio books for the philosopher""" libriVoxGetRequestLinks: [String!]! """An array of identifiers for libravox audio books available for the philosopher""" libriVoxIDs: [String!]! """A string representation of the philosopher's lifespan""" life: String! """The name of the philosopher""" name: String! """An array of quotes by the philosopher""" quotes: [Quote!]! """The school(s) of thought the philosopher is associated with""" school: String """A link to the Stanford Encyclopedia of Philosophy page for the philosopher""" speLink: String """A description of the philosopher's philosophical work as it relates to today""" topicalDescription: String """The 'username' of the philosopher""" username: String! """The title to the Wikipedia page for the philosopher""" wikiTitle: String! """An array of works by the philosopher""" works: [PhilosophicalWork!]! } type PhilosopherWithAudiobook { audiobook: LibriVoxBook! philosopher: PhilosopherResponse! } """Object with information about the philosophical work""" type PhilosophicalWork { """A URL of the link to where the philosophical work may be purchased (typically the Apple Books Store)""" link: String """The title of the philosophical work""" title: String! } """A sentence rewritten in a philosopher's style""" type PhilosophizedText { """The philosopher whose style was used""" philosopherName: String! """The sentence rewritten in the philosopher's style""" text: String! } """Object with information about a quote""" type Quote { """The UUID of the quote""" id: String """The UUID of the philosopher that the quote is from""" philosopherId: String """The quote text""" quote: String! """The UUIDs of the related quotes""" relatedQuotesIds: [String!]! """The work that the quote is from""" work: String """The year the quote was written""" year: String } """A response containing information about a quote and its associated philosopher""" type QuoteWithPhilosopher { """The unique identifier for the quote""" id: String """The philosopher who wrote the quote""" philosopher: PhilosopherResponse! """The quote text""" quote: String! """The work the quote was written in""" work: String """The year the quote was written""" year: String } type RegistrationSuccess { """ID of the newly registered user""" id: String! } """Object with paths to small illustrations of the philosopher""" type SmallIllustrationImages { """A 100x100px thumbnail illustration of the philosopher""" thumbnailIll100x100: String! """A 150x150px thumbnail illustration of the philosopher""" thumbnailIll150x150: String! """A 50x50px thumbnail illustration of the philosopher""" thumbnailIll50x50: String! } """A prior message in a quote reply thread""" input ThreadMessageInput { """Speaker role: "user" or "philosopher"""" role: String! """The message text""" text: String! } """A user profile image""" type UserProfileImage { """Path to the profile image""" url: String! } """Object with paths to profile images for a user""" type UserProfileImages { """Path to the 150x150 profile image""" profile150x150: UserProfileImage! """Path to the 300x300 profile image""" profile300x300: UserProfileImage! """Path to the 450x450 profile image""" profile450x450: UserProfileImage! } """A user account""" type UserResponse { """When the user was created""" createdAt: String """The email of the user""" email: String! """The UUID of the user""" id: String """When the user last logged in""" lastLoginAt: String """The display name of the user""" name: String! """Paths to profile image thumbnails""" profileImage: UserProfileImages """The username of the user""" username: String! }