Create item in a specific group in a specific database

I’m probably blind and/or stupid but how do I create a markdown document in a specific group in a specific database.

More specifically, I want to create a markdown document in a group

/XX/thisyear/thismonth/

In the database mydb

Where thisyear and thismonth are calculated when the note is created.

This on iOS using shortcuts, can anyone give me a clue how to do it?

Are you referring to a group that already exists in DEVONthink To Go?

Ideally I would like to me able to create a document in a group that doesn’t exist yet (much the same I can do using AppleScript) but it looks like I should be able to create a group manually (if necessary) and then create the item there.

If you have any advise to achieve the final result, a new markdown note in a specific group with the pattern “/basegroup/year/month”, I would be grateful (it doesn’t matter if it requires multiple steps).

What is basegroup?

The database contains different documents, I want to collect the notes this shortcut creates in a group (this is what I called basegroup) with subgroups based on year and month, ie

MyBasegroup
  2023
    ...
    11
    12
  2024
    01
    02
    ...
    07
      Some document
      Another document

Creating the group structure is not a huge deal. However, DEVONthink To Go currently will allow creating redundant group structures, so you could create 2024 > 07 multiple times. With the paucity of control in Shortcuts and the current creation actions in DEVONthink To Go, testing for a group’s existence is not as simply done as it is in DEVONthink via AppleScript.

Can I create the document directly in the destination group in a specific database? I couldn’t figure out how to specify that.

PM me.