Skip to content

Getting Started

This content is not available in your language yet.

Developing against divergent Connect couldn’t be simpler with our REST API or official client libraries.

Connect is a full omnichannel communication suite that powers not only its own event-driven APIs used by SaaS products around the globe, but also PureSMS, our simple SMS platform.

To get started, you’ll need to set up your Connect Workspace properly.

  1. Create a Workspace.

    Open PureSMS Open Connect (coming soon)
  2. If you’re not live, make sure you’ve verified your Test Number so that you can send from “ConnectTest”.

    Please note that only numbers from UK, EU and other select countries are currently supported in Test Mode.

    Where do I do this?

    Within Connect or PureSMS, open “Settings” and then “Test Mode”.

  3. If you’re live (or want to go live soon), add at least one Sender name to your Workspace and the Country that you’ll be sending to.

    Where do I do this?

    Within Connect or PureSMS, open “Senders” and then “Create a Sender”.

    You’ll be asked for a Sender Name, Sample Content and at least 1 Country to register the Sender in.

  4. Add a new API Key to your Workspace.

    Where do I do this?

    Within Connect or PureSMS, open “Settings” and then “API Keys”. You can then click “Create API Key”.

  5. 🎉 Ready to go.

Choose your preferred method to send your first SMS.

Install the Divergent.Connect package from NuGet:

Terminal window
dotnet add package Divergent.Connect

Choose the setup method that works best for your application:

Program.cs
var builder = WebApplication.CreateBuilder(args);
// Add Connect client
builder.AddDivergentConnect();
var app = builder.Build();

Add your configuration to appsettings.json:

appsettings.json
{
"Divergent": {
"Connect": {
"ApiKey": "your-api-key",
"DefaultSmsSender": "YourSender"
}
}
}
// Inject IConnectSms into your service/controller (or use the manually built client)
public class MyService(IConnectSms smsClient)
{
public async Task SendWelcomeSms(string phoneNumber)
{
await smsClient.SendSmsAsync(new ConnectSmsMessage
{
To = phoneNumber, // E.164 format, e.g. "+447700900123"
Content = "Hello world, from Connect!"
});
}
}