There's an open GitHub issue for an API that'd add this:
https://github.com/authzed/spicedb/issues/439
The relations are statically defined in your schema, so you could hardcode these values in your application, but it might make rolling schema changes more difficult.