create a task from outside the canvas

How can I create my own buttons but that are outside the canvas to create 3 types of tasks?

You can do this using the same API used in the palette:

const create = modeler.get("create"),
      elementFactory = modeler.get("elementFactory");

const button = document.querySelector("#create-service-task");

button.addEventListener("click", (event) => {
  const shape = elementFactory.createShape({ type: "bpmn:ServiceTask" });

  create.start(event, shape);

CodeSandbox: Custom Palette Example - CodeSandbox

thanks, and if I use a customRendering how do I identify or call it?

Can you explain what you mean?

Create a new element of task type, this element, how do I add it with the solution that you gave me?