DUGU SenderDocumentation Référence API OpenAPI (YAML)

Référence API

POST/api/v1/identities

Create an Email identity (customer Sender Name creation forbidden)

Cet endpoint Email n’est PAS un moyen de creer ou activer un Sender Name SMS. Sender Names are managed by DUGU only. Submit a sender-name request instead. An omitted Email type is normalized to email_from; an explicit sender_name type is refused, even with channel email.

Scope requis : identity.write · Réponses : 200, 403 · Champs requis : name channel

cURL
curl -X POST https://dugusender.com/api/v1/identities \
  -H "Authorization: Bearer <YOUR_API_KEY>" \
  -H "X-Project-Id: votre-project-id" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "sender@example.test",
    "channel": "email"
}'
PHP
use Illuminate\Support\Facades\Http;

$response = Http::withHeaders([
        'Authorization' => 'Bearer '.config('services.dugu_sender.api_key'),
        'X-Project-Id' => config('services.dugu_sender.project_id'),
    ])
    ->timeout(10)
    ->post('https://dugusender.com/api/v1/identities', [
        'name' => 'sender@example.test',
        'channel' => 'email'
    ]);

if ($response->successful()) {
    $data = $response->json();
} elseif ($response->status() === 401) {
    // Cle API absente, invalide ou revoquee.
} elseif ($response->status() === 403) {
    // Cle valide mais scope/capacite/autorisation insuffisante pour cette commande.
} else {
    // Autre erreur (422 validation, 429 rate limit, 5xx) - voir response()->json('error').
}
Node.js
const response = await fetch('https://dugusender.com/api/v1/identities', {
  method: 'POST',
  headers: {
    'Authorization': `Bearer ${process.env.DUGU_SENDER_API_KEY}`,
    'X-Project-Id': process.env.DUGU_SENDER_PROJECT_ID,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    "name": "sender@example.test",
    "channel": "email"
}),
});

const data = await response.json();
Python
import os
import uuid
import requests

response = requests.post(
    'https://dugusender.com/api/v1/identities',
    headers={
    'Authorization': f"Bearer {os.environ['DUGU_SENDER_API_KEY']}",
    'X-Project-Id': os.environ['DUGU_SENDER_PROJECT_ID'],
    },
    json={
        'name': 'sender@example.test',
        'channel': 'email'
    },
)
data = response.json()

GET/api/v1/identities

List activated identities and authorized platform sender

SMS identities require DUGU configuration and activation on the destination route. authorized_countries lists coverage. Pending requests are never usable identities.

Scope requis : identity.read · Réponses : 200

cURL
curl -X GET https://dugusender.com/api/v1/identities \
  -H "Authorization: Bearer <YOUR_API_KEY>" \
  -H "X-Project-Id: votre-project-id"
PHP
use Illuminate\Support\Facades\Http;

$response = Http::withHeaders([
        'Authorization' => 'Bearer '.config('services.dugu_sender.api_key'),
        'X-Project-Id' => config('services.dugu_sender.project_id'),
    ])
    ->timeout(10)
    ->get('https://dugusender.com/api/v1/identities');

if ($response->successful()) {
    $data = $response->json();
} elseif ($response->status() === 401) {
    // Cle API absente, invalide ou revoquee.
} elseif ($response->status() === 403) {
    // Cle valide mais scope/capacite/autorisation insuffisante pour cette commande.
} else {
    // Autre erreur (422 validation, 429 rate limit, 5xx) - voir response()->json('error').
}
Node.js
const response = await fetch('https://dugusender.com/api/v1/identities', {
  method: 'GET',
  headers: {
    'Authorization': `Bearer ${process.env.DUGU_SENDER_API_KEY}`,
    'X-Project-Id': process.env.DUGU_SENDER_PROJECT_ID,
  },
});

const data = await response.json();
Python
import os
import uuid
import requests

response = requests.get(
    'https://dugusender.com/api/v1/identities',
    headers={
    'Authorization': f"Bearer {os.environ['DUGU_SENDER_API_KEY']}",
    'X-Project-Id': os.environ['DUGU_SENDER_PROJECT_ID'],
    },
)
data = response.json()

GET/api/v1/identities/{identityId}

Query Identity Status

Scope requis : identity.read · Réponses : 200

cURL
curl -X GET https://dugusender.com/api/v1/identities/idt_01hxyz \
  -H "Authorization: Bearer <YOUR_API_KEY>"
PHP
use Illuminate\Support\Facades\Http;

$response = Http::withHeaders([
        'Authorization' => 'Bearer '.config('services.dugu_sender.api_key'),
    ])
    ->timeout(10)
    ->get('https://dugusender.com/api/v1/identities/idt_01hxyz');

if ($response->successful()) {
    $data = $response->json();
} elseif ($response->status() === 401) {
    // Cle API absente, invalide ou revoquee.
} elseif ($response->status() === 403) {
    // Cle valide mais scope/capacite/autorisation insuffisante pour cette commande.
} else {
    // Autre erreur (422 validation, 429 rate limit, 5xx) - voir response()->json('error').
}
Node.js
const response = await fetch('https://dugusender.com/api/v1/identities/idt_01hxyz', {
  method: 'GET',
  headers: {
    'Authorization': `Bearer ${process.env.DUGU_SENDER_API_KEY}`,
  },
});

const data = await response.json();
Python
import os
import uuid
import requests

response = requests.get(
    'https://dugusender.com/api/v1/identities/idt_01hxyz',
    headers={
    'Authorization': f"Bearer {os.environ['DUGU_SENDER_API_KEY']}",
    },
)
data = response.json()

POST/api/v1/identities/{identityId}/submit

Submit Email verification (Sender Name mutations forbidden)

Soumission de verification pour une identite Email, y compris les identites Email historiques. Les mutations Sender Name SMS sont reservees a DUGU.

Scope requis : identity.write · Réponses : 200

cURL
curl -X POST https://dugusender.com/api/v1/identities/idt_01hxyz/submit \
  -H "Authorization: Bearer <YOUR_API_KEY>"
PHP
use Illuminate\Support\Facades\Http;

$response = Http::withHeaders([
        'Authorization' => 'Bearer '.config('services.dugu_sender.api_key'),
    ])
    ->timeout(10)
    ->post('https://dugusender.com/api/v1/identities/idt_01hxyz/submit');

if ($response->successful()) {
    $data = $response->json();
} elseif ($response->status() === 401) {
    // Cle API absente, invalide ou revoquee.
} elseif ($response->status() === 403) {
    // Cle valide mais scope/capacite/autorisation insuffisante pour cette commande.
} else {
    // Autre erreur (422 validation, 429 rate limit, 5xx) - voir response()->json('error').
}
Node.js
const response = await fetch('https://dugusender.com/api/v1/identities/idt_01hxyz/submit', {
  method: 'POST',
  headers: {
    'Authorization': `Bearer ${process.env.DUGU_SENDER_API_KEY}`,
  },
});

const data = await response.json();
Python
import os
import uuid
import requests

response = requests.post(
    'https://dugusender.com/api/v1/identities/idt_01hxyz/submit',
    headers={
    'Authorization': f"Bearer {os.environ['DUGU_SENDER_API_KEY']}",
    },
)
data = response.json()

POST/api/v1/sender-name-requests

Submit a Sender Name request (no identity creation or activation)

Requires sender_name.request scope. Organization and project are derived from the authenticated application. Only document references are stored; DUGU must review the private evidence.

Scope requis : sender_name.request · Réponses : 200, 403, 422 · Champs requis : desired_name country document_refs

cURL
curl -X POST https://dugusender.com/api/v1/sender-name-requests \
  -H "Authorization: Bearer <YOUR_API_KEY>" \
  -H "X-Project-Id: votre-project-id" \
  -H "Idempotency-Key: <uuid-genere-cote-client>" \
  -H "Content-Type: application/json" \
  -d '{
    "desired_name": "ACME",
    "country": "SN",
    "document_refs": [
        "00000000-0000-4000-8000-000000000001"
    ]
}'
PHP
use Illuminate\Support\Facades\Http;
use Illuminate\Support\Str;

$response = Http::withHeaders([
        'Authorization' => 'Bearer '.config('services.dugu_sender.api_key'),
        'X-Project-Id' => config('services.dugu_sender.project_id'),
        'Idempotency-Key' => (string) Str::uuid(),
    ])
    ->timeout(10)
    ->post('https://dugusender.com/api/v1/sender-name-requests', [
        'desired_name' => 'ACME',
        'country' => 'SN',
        'document_refs' => [
        '0' => '00000000-0000-4000-8000-000000000001'
    ]
    ]);

if ($response->successful()) {
    $data = $response->json();
} elseif ($response->status() === 401) {
    // Cle API absente, invalide ou revoquee.
} elseif ($response->status() === 403) {
    // Cle valide mais scope/capacite/autorisation insuffisante pour cette commande.
} else {
    // Autre erreur (422 validation, 429 rate limit, 5xx) - voir response()->json('error').
}
Node.js
const response = await fetch('https://dugusender.com/api/v1/sender-name-requests', {
  method: 'POST',
  headers: {
    'Authorization': `Bearer ${process.env.DUGU_SENDER_API_KEY}`,
    'X-Project-Id': process.env.DUGU_SENDER_PROJECT_ID,
    'Idempotency-Key': crypto.randomUUID(),
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    "desired_name": "ACME",
    "country": "SN",
    "document_refs": [
        "00000000-0000-4000-8000-000000000001"
    ]
}),
});

const data = await response.json();
Python
import os
import uuid
import requests

response = requests.post(
    'https://dugusender.com/api/v1/sender-name-requests',
    headers={
    'Authorization': f"Bearer {os.environ['DUGU_SENDER_API_KEY']}",
    'X-Project-Id': os.environ['DUGU_SENDER_PROJECT_ID'],
    'Idempotency-Key': str(uuid.uuid4()),
    },
    json={
        'desired_name': 'ACME',
        'country': 'SN',
        'document_refs': ['00000000-0000-4000-8000-000000000001']
    },
)
data = response.json()

GET/api/v1/sender-name-requests

List requests in the current organization and project

Scope requis : sender_name.request · Réponses : 200

cURL
curl -X GET https://dugusender.com/api/v1/sender-name-requests \
  -H "Authorization: Bearer <YOUR_API_KEY>" \
  -H "X-Project-Id: votre-project-id"
PHP
use Illuminate\Support\Facades\Http;

$response = Http::withHeaders([
        'Authorization' => 'Bearer '.config('services.dugu_sender.api_key'),
        'X-Project-Id' => config('services.dugu_sender.project_id'),
    ])
    ->timeout(10)
    ->get('https://dugusender.com/api/v1/sender-name-requests');

if ($response->successful()) {
    $data = $response->json();
} elseif ($response->status() === 401) {
    // Cle API absente, invalide ou revoquee.
} elseif ($response->status() === 403) {
    // Cle valide mais scope/capacite/autorisation insuffisante pour cette commande.
} else {
    // Autre erreur (422 validation, 429 rate limit, 5xx) - voir response()->json('error').
}
Node.js
const response = await fetch('https://dugusender.com/api/v1/sender-name-requests', {
  method: 'GET',
  headers: {
    'Authorization': `Bearer ${process.env.DUGU_SENDER_API_KEY}`,
    'X-Project-Id': process.env.DUGU_SENDER_PROJECT_ID,
  },
});

const data = await response.json();
Python
import os
import uuid
import requests

response = requests.get(
    'https://dugusender.com/api/v1/sender-name-requests',
    headers={
    'Authorization': f"Bearer {os.environ['DUGU_SENDER_API_KEY']}",
    'X-Project-Id': os.environ['DUGU_SENDER_PROJECT_ID'],
    },
)
data = response.json()

GET/api/v1/sender-name-requests/{requestId}

Read a request in the current organization and project

Scope requis : sender_name.request · Réponses : 200, 404

cURL
curl -X GET https://dugusender.com/api/v1/sender-name-requests/00000000-0000-4000-8000-000000000002 \
  -H "Authorization: Bearer <YOUR_API_KEY>" \
  -H "X-Project-Id: votre-project-id"
PHP
use Illuminate\Support\Facades\Http;

$response = Http::withHeaders([
        'Authorization' => 'Bearer '.config('services.dugu_sender.api_key'),
        'X-Project-Id' => config('services.dugu_sender.project_id'),
    ])
    ->timeout(10)
    ->get('https://dugusender.com/api/v1/sender-name-requests/00000000-0000-4000-8000-000000000002');

if ($response->successful()) {
    $data = $response->json();
} elseif ($response->status() === 401) {
    // Cle API absente, invalide ou revoquee.
} elseif ($response->status() === 403) {
    // Cle valide mais scope/capacite/autorisation insuffisante pour cette commande.
} else {
    // Autre erreur (422 validation, 429 rate limit, 5xx) - voir response()->json('error').
}
Node.js
const response = await fetch('https://dugusender.com/api/v1/sender-name-requests/00000000-0000-4000-8000-000000000002', {
  method: 'GET',
  headers: {
    'Authorization': `Bearer ${process.env.DUGU_SENDER_API_KEY}`,
    'X-Project-Id': process.env.DUGU_SENDER_PROJECT_ID,
  },
});

const data = await response.json();
Python
import os
import uuid
import requests

response = requests.get(
    'https://dugusender.com/api/v1/sender-name-requests/00000000-0000-4000-8000-000000000002',
    headers={
    'Authorization': f"Bearer {os.environ['DUGU_SENDER_API_KEY']}",
    'X-Project-Id': os.environ['DUGU_SENDER_PROJECT_ID'],
    },
)
data = response.json()

Documentation publique en lecture seule. Pour créer une Application et émettre une clé API, connectez-vous à DUGU Sender (Developer Platform). Aucune clé réelle n'est affichée ici.