In case a user does not want to reveal a segment due to it having sensitive information, it can be hard to figure out exactly what the hash for a segment is (especially when there is an encoding or related problem). So adding it to the API output can be useful for debugging.
Added the test. also added the extra urlencode for the definition. Will wait until the other pr is merged before merging this one.
which is the other pr you are waiting for? maybe it's merged already now?
I guess this one might meanwhile be obsolete. The hash should already be included in the API response. ping @diosmosis
Yes, unnecessary, closing this