Introduction

Welcome to the FlareSend API documentation. This guide provides specifications for connecting your systems to the FlareSend Application. Primarily, you can connect to perform the following:

  • Create user accounts
  • Authenticate users
  • Create WhatsApp instances
  • Send messages via WhatsApp

All requests MUST be made over HTTP/HTTPS. Calls without proper authorization will fail.

Next

Authorization

FlareSend uses API keys and bearer tokens for access. Create an account and login to obtain a token. Use the token in subsequent calls via the Authorization header: Authorization: Bearer {token}.

← Back
Next

Errors

The FlareSend API uses the following error codes:

Error Code Meaning
400 Bad Request -- Your request is invalid.
401 Unauthorized -- Your API key or token is wrong.
403 Forbidden -- The resource requested cannot be accessed.
404 Not Found -- The specified resource could not be found.
500 Internal Server Error -- We had a problem with our server. Try again later.
← Back
Next

Create Account

Register a new user account to start using the API.

POST https://api.flaresend.io/register

Header Description
api-key Your unique API key (e.g., 1acdff9afe3fcbf788d06df07057d29cbc18d02deafb0e71f004510f8b120e4e)
Content-Type application/json
Parameter Required Type Description
firstname yes string User's first name
lastname yes string User's last name
email yes string User's email address
password yes string User's password
curl --location 'https://api.flaresend.io/register' \
--header 'api-key: 1acdff9afe3fcbf788d06df07057d29cbc18d02deafb0e71f004510f8b120e4e' \
--header 'Content-Type: application/json' \
--data-raw '{
    "firstname": "Sos",
    "lastname": "Mongare",
    "email": "sosmongare@gmail.com",
    "password": "admin123"
}'
                
{
  "status": "success",
  "user_id": "u123456",
  "message": "Account created successfully",
  "created_at": "2025-09-26T11:50:00Z"
}
                
{
  "error_code": 400,
  "error_message": "Invalid request parameters"
}
                
← Back
Next

Login

Authenticate an existing user to receive an access token.

POST https://api.flaresend.io/login

Header Description
api-key Your unique API key
Content-Type application/json
Parameter Required Type Description
email yes string User's email
password yes string User's password
curl --location 'https://api.flaresend.io/login' \
--header 'api-key: 1acdff9afe3fcbf788d06df07057d29cbc18d02deafb0e71f004510f8b120e4e' \
--header 'Content-Type: application/json' \
--data-raw '{
    "email": "sosmongare@gmail.com",
    "password": "admin123"
}'
                
{
  "status": "success",
  "access_token": "1acdff9afe3fcbf788d06df07057d29cbc18d02deafb0e71f004510f8b120e4e",
  "token_type": "Bearer",
  "expires_in": 3600
}
                
{
  "error_code": 401,
  "error_message": "Invalid credentials"
}
                
← Back
Next

Create Instance

Create a new WhatsApp instance for messaging.

POST https://api.flaresend.io/instances

Header Description
api-key Your unique API key
Authorization Bearer token for authentication

No body parameters required.

curl --location --request POST 'https://api.flaresend.io/instances' \
--header 'api-key: 1acdff9afe3fcbf788d06df07057d29cbc18d02deafb0e71f004510f8b120e4e' \
--header 'Authorization: Bearer 1acdff9afe3fcbf788d06df07057d29cbc18d02deafb0e71f004510f8b120e4e' \
--data ''
                
{
  "status": "success",
  "instance_id": "inst123456",
  "message": "Instance created successfully",
  "created_at": "2025-09-26T11:50:00Z"
}
                
{
  "error_code": 401,
  "error_message": "Unauthorized"
}
                
← Back
Next

Send Message

Send WhatsApp messages to one or multiple recipients.

POST https://api.flaresend.io/send-message

Header Description
api-key Your unique API key
Content-Type application/json
Authorization Bearer token for authentication
Parameter Required Type Description
recipients yes array Array of recipient phone numbers
type yes string Message type (e.g., "text")
text yes string The message text
curl --location 'https://api.flaresend.io/send-message' \
--header 'api-key: 1acdff9afe3fcbf788d06df07057d29cbc18d02deafb0e71f004510f8b120e4e' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer 1acdff9afe3fcbf788d06df07057d29cbc18d02deafb0e71f004510f8b120e4e' \
--data '{
    "recipients": ["254762043910","254735733119"],
    "type": "text",
    "text": "Good morning, Sent from Whatsapp API"
}'
                
{
  "status": "success",
  "message_id": "msg123456",
  "recipients": ["254762043910", "254735733119"],
  "message": "Message sent successfully",
  "sent_at": "2025-09-26T11:50:00Z"
}
                
{
  "error_code": 400,
  "error_message": "Invalid request"
}
                
← Back