/string to get a string, do <click:run_command:@(your command)> and put the text after that and check the command using player event run command and if command =. (you do need Emporer for commands) but you can also do <click:copy_to_clipboard:70084> which doesn't need any rank