How to change the citation key for Zotero sync?

I use Zotero sync with Typst Premium. When syncing my library to Typst it creates a bib file with the wrong citation key.

Instead of using the author it creates the citation key using the editor. The same happens with collections where it also creates the key with the editor. How can I change that?
It’s extremely confusing when writing a text and also have to use the editor instead of the author to cite.

@article{legrand_journalistische_2023,
	location = {Frankfurt am Main},
	title = {Journalistische Grenzgänger: Wie die Reportage-Formate von funk Wirklichkeit konstruieren},
	url = {https://www.otto-brenner-stiftung.de/fileadmin/user_data/stiftung/02_Wissenschaftsportal/03_Publikationen/AH111_Funk.pdf},
	number = {111},
	publisher = {Otto Brenner Stiftung},
	author = {Brinkmann, Janis},
	editor = {Legrand, Jupp},
	urldate = {2025-06-19},
	date = {2023},
	langid = {german},
	keywords = {ausgewählt},
}

In the example above it uses Legrand but should use Binkmann.

When using the standard local BibTex export in Zotero the citation key comes out just as expected

@article{brinkmannJournalistischeGrenzgaengerWie2023,
	address = {Frankfurt am Main},
	title = {Journalistische {Grenzgänger}: {Wie} die {Reportage}-{Formate} von funk {Wirklichkeit} konstruieren},
	url = {https://www.otto-brenner-stiftung.de/fileadmin/user_data/stiftung/02_Wissenschaftsportal/03_Publikationen/AH111_Funk.pdf},
	language = {de},
	number = {111},
	urldate = {2025-06-19},
	publisher = {Otto Brenner Stiftung},
	author = {Brinkmann, Janis},
	editor = {Legrand, Jupp},
	year = {2023},
	keywords = {ausgewählt},

I have the BetterBibTex PlugIn installed.

I found a solution and it was actually a very easy fix.
Because BetterBibTex generated the citation key it needs to be “pinned to the entry”.
Right click an entry in Zotero (or Ctrl+a to select all) ->BetterBibTex → Pin citation key.
Sync everything and et voilà! Typst now has the correct citation key as in Zotero.

See this link for more info on citation keys with BetterBibTex: Citation Keys :: Better BibTeX for Zotero

1 Like