The prisma client has what it calls a "fluent" API, which allows you to chain requests for sub-types but work with them all as if they were a promise (docs). Example:
const organization = await prisma.schedule({id: "foo"{}).organization();
All of the examples in the documentation demonstrate using async
/await
syntax when working with the client. Inspecting what gets returned from a call to the client shows then
and catch
properties, like a normal promise, as well as the other fields exposed as functions (which is what allows the fluent API).