zotero://select for collections
Is it possible to use a
zotero://select
link for a collection? Or, alternatively to link to an item in a specific collection?
zotero://select/library/collections/:collectionKey
zotero://select/groups/:groupID/collections/collectionKey
Could you please add a "Copy zotero://select link" entry to the collection context menu ?
Thanks in advance !
So, if there's no way for Zotero users to come up to the right zotero://select link by themselves, how did you expect them to benefit from this feature when implementing it ? I'm feeling like I'm missing something here...
The item version was originally an internal mechanism used for the (ancient) timeline feature. Some people found it useful in other contexts and Zutilo added the ability to generate it. The same thing can happen here. But I doubt enough people would use it to merit default context-menu options.
In the meantime, if you're using syncing, you can see the collection key in the URL when you click on the collection in the web library.
But when I try to select a specific item in a specific collection using the following:
zotero://select/groups/:groupID/collections/collectionKey/items/item.libraryID_item.key (OR just item.key no library id, it gives the same result)
Or the same in my library:
zotero://select/library/collections/:collectionKey/items/item.libraryID_item.key
(example)
zotero://select/groups/2321942/collections/YH5INLCB/items/6_J7G9KP3R
It selects all items of the collection in library view if in a different collection
or if I am already in the collection it selects all items in the collection.
What am I missing? if zotero it could send me to an specific item and collection it would help a lot to move quickly around collections using notes to store the links.
But I just tried it but I couldn't get it to work in neither my group nor my library.
I am using zotero standalone, 5.0.67-beta.12+6ba6028ed:
Here was the improvement from the commit message
Fix the 'itemKey' parameter:
zotero://select/library/collections/:collectionKey/items?itemKey=:itemKey1,:itemKey2
I tried it in a group This link to a collection works fine.
zotero://select/groups/2297866/collections/6WXTWPYV
Using the same collection and group I tried selecting an item using item.key
but the hyperlink wasn't clickable in both examples
zotero://select/library/collections/6WXTWPYV/items?itemKey=NM6AQ84Y
zotero://select/library/collections/6WXTWPYV/items?itemKey=3_NM6AQ84Y
In my library neither of two worked as well
zotero://select/library/collections/TE5FLTMQ/items?itemKey=0_LYDK57CH
zotero://select/library/collections/TE5FLTMQ/items?itemKey=LYDK57CH
I used a translator to tried to find the itemKey2
Using item.key2 (undefined) and itemKey2 (error when exporting)
Also using the this that was also in that page also led to an unclickable link
- Support items within collections and searches:
zotero://select/groups/:groupID/collections/:collectionKey/items/:itemKey
zotero://select/groups/2321942/collections/YH5INLCB/items/6_J7G9KP3R
I tried this with different item types, with the same result.
Any hints on how to make it work? I am really excited to use this feature!
I have no further questions regarding its use, this post is to explain how to use it.
My mistake was getting too caught up trying to follow the example :
zotero://select/library/collections/:collectionKey/items?itemKey=:itemKey1,:itemKey2
How to use
As dstillman said the item must be in the collection,
If it is there via recursive collections it won't work on that item.
It does work even if the same item is in different collections (if you use different collection keys)
Both using /items or /items?itemKey= work
For personal collections
You only need the collection key and item key
zotero://select/library/collections/UNLPD5ET/items?itemKey=LYDK57CH
For groups
As dstilman said it, it has to say groups first as in the functionality to jump to a specific collection. Otherwise it won't work
So you need in addition to the collection and item key the group id (in the url of a group it shows is a number not the name of the group)
zotero://select/groups/2297866/collections/KD26G5DG/items?itemKey=QTATT2AI
Thank you for taking the time to explain it to me! dstillman
I am trying find a way to get the collection key from an export translator to include the improvements to zotero select that dstillman added in my version of his uri translator.
But zotero.json above doesn't provide me with the collection key as it you mention it can. It shows the group id and item key.
I think I tried all the built-in options that allow for an export translator in zotero standalone to find the collection key, without success in finding the collection key.
This is what using zotero.json displays for this item
zotero://select/groups/2297866/collections/KD26G5DG/items?itemKey=QTATT2AI
{
"itemType": "bookSection",
"extra": "C",
"title": "' ' P . 2. ",
"creators": [],
"tags": [
{
"tag": "\"",
"type": 0
},
{
"tag": "@",
"type": 0
},
{
"tag": "<",
"type": 0
}
],
"attachments": [],
"notes": [
{
"key": "8P9NAVYK",
"itemType": "note",
"parentItem": "QTATT2AI",
"note": "",
"tags": [],
"relations": {},
"dateAdded": "2019-05-23 00:02:37",
"dateModified": "2019-05-23 00:02:37",
"uri": "http://zotero.org/groups/2297866/items/8P9NAVYK",
"uniqueFields": {},
"itemID": 11816,
"libraryID": 3,
"sourceItemKey": "QTATT2AI",
"seeAlso": []
}
],
"itemID": 11321,
"seeAlso": []
}
The following procedure works for me. With Better BibTeX installed, the context menu for a collection folder includes "Show BibLaTeX server URL". An URL will pop up:
http://localhost:23119/better-bibtex/collection?/1/[collectionKey].biblatex
Copy [collectionKey] and use zotero://select/library/collections/[collectionKey]
not working:
zotero://select/library/searches/[searchKey]
working:
zotero://select/library/searches/[searchKey]/items/[itemKey]
zotero://select/library/searches/[searchKey]/items?itemKey=[itemKey1],[itemKey2]
The three links with "collections" instead of "searches" all work fine.
items in library
zotero://select/library/items/[itemKey]
zotero://select/library/items?itemKey=[itemKey1],[itemKey2]
collections in library
zotero://select/library/collections/[collectionKey]
zotero://select/library/collections/[collectionKey]/items/[itemKey]
zotero://select/library/collections/[collectionKey]/items?itemKey=[itemKey1],[itemKey2]
searches in library
zotero://select/library/searches/[searchKey]
zotero://select/library/searches/[searchKey]/items/[itemKey]
zotero://select/library/searches/[searchKey]/items?itemKey=[itemKey1],[itemKey2]
@dstillman - quick question on this. Does a translator know which collection the right click was made? Obviously the item has the list of collections it's in. However, is the information about where the right-click occurred passed to the transaltor?
zotero://select/library/
. The code seems to be available in the protocol handler (here), but it's not used and the Debug Output Logging shows "No objects specified". Could you add support for selecting the root of library or groups?