-
Notifications
You must be signed in to change notification settings - Fork 668
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
[discovery] Add sort parameter for Discovery query #446
[discovery] Add sort parameter for Discovery query #446
Conversation
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.
LGTM
* @param {Number} [params.offset=0] For pagination purposes. Returns additional pages of results. Deep pagination is highly unperformant, and should be avoided. | ||
* @param {String} [params.return] A comma separated list of the portion of the document hierarchy to return. | ||
* @param {String} [params.sort] A comma separated list of fields in the document to sort on. You can optionally specify a sort direction by prefixing the field with - for descending or + for ascending. Ascending is the default sort direction if no prefix is specified. |
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.
Is sorting supported in the newest version and should the default version string change?
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.
so its available in the newest version, just not sure what to do about the version string. i.e. it will work with any version date string since it isn't changing an existing parameter behavior, but adding a new one
So if I pass the old version string it will still sort?
…On Thu, Apr 27, 2017, 3:12 PM Andrew Turgeon ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In discovery/v1.js
<#446 (comment)>
:
> * @param {Number} [params.offset=0] For pagination purposes. Returns additional pages of results. Deep pagination is highly unperformant, and should be avoided.
+ * @param {String} [params.return] A comma separated list of the portion of the document hierarchy to return.
+ * @param {String} [params.sort] A comma separated list of fields in the document to sort on. You can optionally specify a sort direction by prefixing the field with - for descending or + for ascending. Ascending is the default sort direction if no prefix is specified.
so its available in the newest version, just not sure what to do about the
version string. i.e. it will work with any version date string since it
isn't changing an existing parameter behavior, but adding a new one
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#446 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAB8wkCC4AISdUXAX9V3_B44hlbqlpzsks5r0OiYgaJpZM4NKpH9>
.
|
correct |
At some point, |
61aed8c
to
a5dc23f
Compare
a5dc23f
to
99c0daa
Compare
Description
Adds the
sort
parameter to the Discoveryquery
method -> see https://watson-api-explorer.mybluemix.net/apis/discovery-v1#!/Queries/get_v1_environments_environment_id_collections_collection_id_query for detailsChecklist
npm test
passes (tip:npm run autofix
can correct most style issues)New version_date Checklist