You can select the Type of authentication in the settings of your published api. None, Username/Password or custom.
To get the big picture follow this “Configure Security and Access Management” learning path: https://gettingstarted.mendixcloud.com/link/path/37