Using REST api to send a mac command

Hello,
Trying to use the REST api to send a mac command to the end node. I am trying to use the add to queue in the api in order to send a message on the downlink and I’m encountering several problems:

  1. the API sends the message on the gateway topic instead of the application topic. I can’t understand why to use the gateway in this scenario, because the destination of the message is the end node.
  2. the add to queue command needs a message that is in base64, which causes and extra level of decoding in the pipeline and the message to be unreadable when it reaches the end node. How can I send a message (preferable legit mac command) to the end node using the add to queue command in the API (or if there is any other command that can help that would be great)

Thanks!

There is already an other topic with the same question: Sending MAC commands with the Application Server REST API.