navto
Login

API Documentation

Manage your WhatsApp links using the navto API. Comprehensive API documentation for WhatsApp messaging and QR code integration.

WhatsApp Redirect API
Start a WhatsApp chat with phone number and message

WhatsApp URL

Start a WhatsApp chat with phone number and message

// Client-side function
import { generateWhatsAppUrl } from "@/lib/whatsapp"

// Generate WhatsApp URL
const url = generateWhatsAppUrl(phone, text)

// Example
const url = generateWhatsAppUrl("+905551234567", "Hello!")
// Returns: https://wa.me/905551234567?text=Hello!

Endpoint

GET /wp?phone=PHONE_NUMBER&text=MESSAGE

Parameters

phone

Phone number to start WhatsApp chat with. Must contain only numbers including country code. Example: 905551234567

text (optional)

Message to be sent automatically when chat starts. Must be URL-encoded.

Example Usage

With phone number only:

https://navto.app/wp?phone=905551234567

With phone number and message:

https://navto.app/wp?phone=905551234567&text=Hello%2C%20I%20need%20information

Notes

  • Phone number can contain spaces, dashes, or plus sign - they will be automatically removed
  • Country code can be provided with or without + sign
  • Message parameter must be URL-encoded
  • API redirects user to WhatsApp Web or WhatsApp app
  • All phone numbers are automatically formatted correctly