This repository has been archived on 2026-01-31. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
calendar-demo/server/src/schema.graphql
2022-07-15 23:12:37 +02:00

74 lines
1.1 KiB
GraphQL

type Query {
info: String!
feed(
filter: String
skip: Int
take: Int
orderBy: AppointmentOrderByInput
): Feed!
allAppointments: [Appointment]
oneAppointment(_id: ID!): Appointment
}
type Feed {
id: ID!
appointments: [Appointment!]!
count: Int!
}
type Mutation {
createAppointment(
title: String!
description: String
type: String!
start: DateTime!
end: DateTime!
deleted: Boolean
): Appointment!
updateAppointment(
_id: ID!
title: String!
description: String
type: String!
start: DateTime!
end: DateTime!
deleted: Boolean
): Appointment
deleteAppointment(_id: ID!): Appointment
}
type Subscription {
newAppointment: Appointment
}
# Appointment schemas
type Appointment {
_id: ID!
title: String!
description: String
type: String!
start: DateTime!
end: DateTime!
deleted: Boolean
}
input AppointmentInput {
title: String!
description: String
type: String!
start: DateTime!
end: DateTime!
deleted: Boolean
}
input AppointmentOrderByInput {
title: Sort
desc: Sort
}
# General-purpose schemas
enum Sort {
asc
desc
}
scalar DateTime
scalar Time