-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Update APIv3 documentation with latest changes #5895
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
Conversation
humitos
commented
Jul 9, 2019
•
edited
Loading
edited
- Added Redirects documentation
- Remove Users documentation
- Added Project Import documentation
- Make sure the fields in the responses match the returned ones
- Add a note inviting users to request for beta testing
docs/api/v3.rst
Outdated
+++++++++++++++++++ | ||
Redirects allow the author to redirect an old URL of the documentation to a new one. | ||
This is useful when pages are moved around in the structure of the documentation set. | ||
See :doc:`user-defined-redirects` for more information. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@stsewd do you know why this does not work? We are doing exactly the same in the index.rst
page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The doc role search for relative paths, here you need to search from an absolute path (:doc:`/user-defined-redirects
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like good changes, just a few comments.
docs/api/v3.rst
Outdated
"xafer", | ||
"pradyunsg" | ||
{ | ||
"created": "2010-10-23T18:12:31+00:00", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we want to expose this data do we? I don't really see how it's useful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm removing it for now. We can add user's fields later if we consider without breaking anything.
-X POST \ | ||
-H "Authorization: Token <token>" https://readthedocs.org/api/v3/projects/ \ | ||
-H "Content-Type: application/json" \ | ||
-d @body.json |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we also include a Python example?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would be pretty handy. I will create an issue for this to use tabs (Python + Slumber and cURL).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Issue at #5935
+++++++++++++++++++ | ||
Redirects allow the author to redirect an old URL of the documentation to a new one. | ||
This is useful when pages are moved around in the structure of the documentation set. | ||
See :doc:`/user-defined-redirects` for more information. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should probably put a similar description for all the resources (eg. Translations)
docs/api/v3.rst
Outdated
:statuscode 400: Some field is invalid | ||
|
||
|
||
Redirect destroy |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think delete
is probably more common than destroy
-- we should standardize on one.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
He, yeah. The verb is DELETE but DRF uses destroy so 🤷♂️
I think delete makes more sense here.
@ericholscher I made some changes to the PR. Feel free to merge if you consider that's ready. Otherwise, let me know. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. 👍