-
Notifications
You must be signed in to change notification settings - Fork 14
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
Add query param flag for retrieving collections by curator name and visibility in GET /collections
index endpoint
#2793
Comments
@brianraymor I'm seeing a comment on the other issue from you said
I'm assuming this means then that we should include both public and private Collections in the response (since it's mimicking the UI endpoint that curators are familiar with, which displays both). |
That is correct.
|
Wait, this is different than what is returned when visiting |
Doh. Writing too fast. Yes - all collections private or public that I'm authorized to see. Lead curators see everything. Other curators see only their collections. |
I'm still unclear on whether that means a non-super curator should get back, in addition to their private Collections... all public Collections OR just their own public Collections. 😅 |
just their own public collections - MyCollections like a filter collections by curator.
That's an interesting question for @jahilton since he has recently requested filtering in the MyCollections UX. See Curator can filter "My collections" by curator and status. |
If I'm understanding the Q correctly... |
Yes, both public and private, but insofar as the public Collections are concerned, I presume it should only be the public Collections which the curator owns/has write access for. For super curators this is all public Collections. For non-super curators this is just their own public Collections. |
👍 |
Good question, Brian. |
@brianraymor thanks for clarifying. Yes, I would prefer that endpoint with the similar filters to specify. |
Re the related issue of filtering by curator in the UI @Bento007 if we were to do this via the API we would have to figure out how we would implement an ability for the curator to specify which curator they want to retrieve collections for. This makes me think that, despite my comments on the linked issue, we'd actually prefer to have this be a UI feature since it would drastically simplify the problem of implementing 'text search -> single Auth0 user', which is a whole different can of worms (correct me if I'm wrong). |
@jahilton @brianraymor is it considered acceptable if the curator submits a query param |
I expect to query all Collections in the data corpus, and browsing those, I will see the curator names. |
Per my comment from yesterday's very long slack thread:: I don't see why I would need search when it's simple to return a list of curators for an API user to choose from. Here's the current set: {'Batuhan Cakir', For example: or per Jason's remarks - extract one out of previous query. |
GET /collections
index endpointGET /collections
index endpoint
Yep, this sounds like a reasonable plan. I had been thinking we wanted a more sophisticated functionality for a single call. But this works if it's what you want. Thank you guys for the comments! |
Adding comments from the linked PR: This API is targeted at super curators. Currently, they are authorized to see all collections, so a filter is proposed as a convenience. The example below assume that a valid curator name is passed as the parameter. Here's how I imagine the experience: User
Curator
Super Curator
|
@Bento007 so, according to the above, we're getting rid of |
I moved this back to Ready for Staging until Jason and I can review and test. |
This was decided in slack that |
@Bento007 - initial testing is looking good, but I have some questions.
|
I'll change it to forbidden. I would only be concerned if "Mister Peanut" had more than 0 collections, and we returned 0. Otherwise, that is by design. |
There's a slight difference in status codes returned: User -> 401 |
That would be my expectation |
@Bento007 - the results look good for super curator. I can filter collections by curators for both public and private collections. Once the status code is addressed, then this is ready for production. |
@brianraymor what request did you send that returned a 400? |
Hmm. Earlier, I was seeing it only for the curator role notebook. I did a restart and clear output on the kernel. Now, I'm seeing 401(s) for both curator and user. |
August 8: There was agreement to remove this issue from the curation API MVP. It's not required for the 3.0.0 migration and can be considered in parallel with the symmetrical curation UX request..
Update: See curation-api.
access_type
MUST also be removed from responses and the Swagger API.see #2083 (comment)
Add a query param
MyCollections
flag (or similar) that causesGET /collections
to return only Collections which are owned by the curator making the call.@brianraymor @jahilton should visibility be specified? Or should the usage of this flag default to returning all of a curator's Collections, both public and private? **edit**: see comment below
The text was updated successfully, but these errors were encountered: