The item ID for Sweet Gem Berry in Stardew Valley is:
The above cheat code applies to all platforms including PC/Mac (Steam), XBOX One, PS4 and the Nintendo Switch.
Spawning items in Stardew Valley is not done via commands, but rather through a cheat in which you must set your character's name, or the name of an animal, to the item code of the item you wish to spawn surrounded by [ and ].
To spawn this item using an animal's name, visit Marnie's Ranch, speak to Marnie and purchase an animal (we recommend a chicken as it is cheapest). Name the animal  and press OK. You will then receive the sweet gem berry item.
You can only set your character's name once, at the start of the game (when you create your world), for this reason we recommend you use the animal name method. If you do wish to use this method, first set your character's name to  when creating your save. Whenever you speak to a villager that says your name in dialogue (for example Gus at the Stardrop Saloon) you will be given the sweet gem berry item.
If you need more help with spawning sweet gem berry, we have a detailed guide on our blog - click here to visit that page.
Sweet Gem Berries are grown from rare seeds. They take 24 days to grow into fully mature plants. You can purchase a sweet gem berry from the Traveling Cart for a gold price between 9,000 and 15,000 (although the price for Rare Seeds is much lower, 600-1,000). Sweet Gem Berries can be turned into up to 3 seeds using a Seed Maker (there is a 2.5% chance that you will not receive any seed).
It's by far the sweetest thing you've ever smelled.