decentralized-identity / hub-node-core

Node.js implementation of the Identity Hub interfaces, business logic, and replication protocol.
Apache License 2.0
17 stars 7 forks source link

CommitQueryRequests: can object_id and revision be combined? #14

Open llorllale opened 5 years ago

llorllale commented 5 years ago

I'd like clarification of whether the spec for CommitQueryRequests allows object_id and revisions to be used together (presumably so that revisions would further constrain the commits returned by the objects identified by object_id).

The spec for the format reads here:

Currently the only supported fields in the query object are object_id (to retrieve all commits for an object) and revisions (to retrieve a specific list of revisions).

This text is mute regarding the combined use of these two fields.

The implementation though has a comment saying they're mutually exclusive, but curiously enough it returns a not_implemented error_code, as opposed to bad_request:

https://github.com/decentralized-identity/hub-node-core/blob/1967c076f64e64969065aeb99b0e235272d62089/lib/models/CommitQueryRequest.ts#L25-L32