Kinto / kinto.js

An Offline-First JavaScript Client for Kinto.
http://kintojs.readthedocs.io/
Other
318 stars 71 forks source link

Support custom resource API endpoints #1751

Open slav0nic opened 4 years ago

slav0nic commented 4 years ago

Kinto internally allow register custom colander based Resource, but i don't see any functionality related to this in kinto-http.js

all kinto-http.js API works only with bucket/collections, but what to do with endpoints like /mushrooms/ from this example?

If this possible, will be fine document it.

dstaley commented 4 years ago

The documentation you linked is for kinto.core, which powers kinto, the server/API this library is designed for. I don't think kinto allows for defining custom resources (instead you'd set a schema on a collection), but I'll let @leplatrem confirm.

slav0nic commented 4 years ago

But kinto also support plugins that internally have all of this, for example /accounts/ endpoint don't use bucket/collection, is it possible get listing via kinto-http.js for existing accounts for example? Kinto/kinto.js#1757 related

Natim commented 4 years ago

It is true that Kinto gives a toolkit to be able to create Resources on other endpoints.

I don't think today kinto-http.js is able to configure totally custom urls. but it might be a nice addition indeed.