Register SMTP

Register your SMTP credentials

Register Credentials

post

Register Mailer

This endpoint allows you to register a mailer with the provided SMTP configuration.

Request Body

  • api_username (string): Your Pay Hero API username for authentication.

  • smtp_host (string): The SMTP host for the mailer configuration.

  • smtp_username (string): The SMTP username for authentication.

  • smtp_password (string): The SMTP password for authentication.

  • smtp_port (string): The SMTP port for the mailer configuration.

Response

  • id (string): The ID of the registered mailer.

  • message (string): A message indicating the status of the registration process.

Example:

{
  "id": "",
  "message": ""
}

Body
objectOptionalExample: {"api_username":"cQRGoMOqwBv94WB","smtp_host":"host.com","smtp_username":"[email protected]","smtp_password":"&!password^Frx1","smtp_port":"465"}
Responses
200
OK
application/json
Responseobject
post
POST /mailer/register HTTP/1.1
Host: applet.payherokenya.com
Content-Type: application/json
Accept: */*
Content-Length: 141

{
  "api_username": "cQRGoMOqwBv94WB",
  "smtp_host": "host.com",
  "smtp_username": "[email protected]",
  "smtp_password": "&!password^Frx1",
  "smtp_port": "465"
}
{
  "id": "2",
  "message": "Credentials registered successfully"
}

Was this helpful?