Check out our Launch week free trial and the Polymorfa Builders Program! 15 Pro numbers + add-ons for 30 days.

Ends in ––d : ––h : ––m : ––s

Command Palette

Search for a command to run...

sdks · typescript · python · go · php · rust

Official SDKs in five languages.

Typed WhatsApp clients with the same authentication, endpoints, and behavior in each language. Pick the language you already use.

npm

TypeScript

Fully typed TypeScript/JavaScript client for Node.js, Deno, and Bun.

npm install @polymorfa/sdk
send.ts
import { Polymorfa } from '@polymorfa/sdk'

const polymorfa = new Polymorfa({ apiKey: process.env.POLYMORFA_KEY! })

await polymorfa.sessions.messages.send('my-session', {
  to: '5511999999999',
  type: 'text',
  text: { body: 'Hello from Polymorfa!' },
})

pip

Python

Pythonic async/sync client. Great for data pipelines, bots, and scripts.

pip install polymorfa-sdk
send.py
from polymorfa import Polymorfa

polymorfa = Polymorfa(api_key=os.environ["POLYMORFA_KEY"])

polymorfa.sessions.messages.send(
    session_id="my-session",
    to="5511999999999",
    type="text",
    text={"body": "Hello from Polymorfa!"},
)

go get

Go

Idiomatic Go client with full type safety. For high-performance services.

go get github.com/polymorfa/polymorfa-sdk-go
send.go
package main

import (
	"context"
	"os"

	polymorfa "github.com/polymorfa/polymorfa-sdk-go"
)

func main() {
	c := polymorfa.New(os.Getenv("POLYMORFA_KEY"))
	_, _ = c.Sessions.Messages.Send(context.Background(), "my-session", polymorfa.Message{
		To:   "5511999999999",
		Type: "text",
		Text: &polymorfa.Text{Body: "Hello from Polymorfa!"},
	})
}

composer

PHP

Composer package for Laravel, Symfony, and vanilla PHP projects.

composer require polymorfa/polymorfa-php
send.php
<?php
use Polymorfa\Polymorfa;

$polymorfa = new Polymorfa(getenv('POLYMORFA_KEY'));

$polymorfa->sessions->messages->send('my-session', [
    'to'   => '5511999999999',
    'type' => 'text',
    'text' => ['body' => 'Hello from Polymorfa!'],
]);

cargo

Rust

Zero-cost abstractions client. Compile-time type checking for the Polymorfa API.

cargo add polymorfa-sdk
send.rs
use polymorfa_sdk::{Polymorfa, Text};

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let t = Polymorfa::new(std::env::var("POLYMORFA_KEY")?);

    t.sessions()
        .messages()
        .send("my-session")
        .to("5511999999999")
        .text(Text::new("Hello from Polymorfa!"))
        .await?;

    Ok(())
}

Prefer raw HTTP? The API ships an OpenAPI 3.0 spec and a Postman collection to generate your own client in any language.

Start shipping.

Every SDK covers the full API surface. No feature gaps between languages.