graphiti-api / spraypaint.js

Graphiti Client / Javascript ORM / JSONAPI
MIT License
108 stars 69 forks source link

[Question] Custom routes and actions #77

Open lucianholt97 opened 4 years ago

lucianholt97 commented 4 years ago

I was wondering how to implement fetching the currently active user. Normally, I would just call /api/v1/user. How can I achieve this behaviour with spraypaint?

Besides, a related question is concerning actions (which are indicated in the route). For example I would like a post by performing a get request to /api/v1/posts/1/like. Is there a possibility to add something to the route in a find request?

Thanks in advance!