@webline, take a look at the stamp code used here, Replacing the Linktype of a link between notes with action code in a stamp?.
In your action code you could also use stamp(“this action”). This is a method I use to apply action code to a specific note. There are of course, other methods.