-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
API: use restricted serializer for related projects #11820
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
readthedocs/api/v3/serializers.py
Outdated
model = Project | ||
fields = [ | ||
"id", | ||
"name", |
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 wonder if we should exclude the name from restricted objects as well (restricted organization is the other serializer like this)
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 confused about what we talked in our meeting and what we are implementing here. I understood we were going in another direction. Can you explain more your thoughts here and what are the next steps based on the context I've shared?
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.
This approach seems good to me. I'm not in love with doing a bunch of nested values in API responses, and I think in general folks can re-query the API for the returned project if they need the data.
Not sure if we need a note in the API docs/blog about this, or if we're just guessing folks aren't currently using this data?
Putted a note in the docs |
Ref https://github.com/readthedocs/readthedocs-corporate/issues/1845