-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow making requests at the root of an API #28
Comments
Yes this is planned for the next release (0.5). |
You could access API root like this: api.__getattr__('').get() or even better like this: getattr(api, '').get() First way is also useful if your API URL contains reserved words like get, post... api.files.__getattr__('get').get() # GET /api/v1/files/get |
When you have reserved words, doesn‘t api.files('get').get() work? @dstufft Was this fixed or is it still in planning? |
@merwok Don't believe I ever fixed it :/ If I recall I was essentially going to turn the API object into a resource with a different constructor to handle the initial creation. |
Unless I've missed something, it doesn't seem to be possible to make a request to the root URL of an API. Maybe instead of returning an API object, you should just get a fully functional resource from the get go?
The text was updated successfully, but these errors were encountered: