Trunk SIP
Connecter Asterisk ou FreePBX
Exemple de configuration PJSIP et réglages FreePBX.
Les valeurs à utiliser (serveur, domaine, identifiant, mot de passe) sont dans Trunks SIP › Identifiants de connexion.
Asterisk (PJSIP)
[hcloud]
type=registration
outbound_auth=hcloud-auth
server_uri=sip:VOTRE-SERVEUR:5070
client_uri=sip:IDENTIFIANT@VOTRE-DOMAINE
[hcloud-auth]
type=auth
auth_type=userpass
username=IDENTIFIANT
password=MOT-DE-PASSE
[hcloud]
type=aor
contact=sip:VOTRE-SERVEUR:5070
[hcloud]
type=endpoint
context=from-hcloud
disallow=all
allow=alaw,ulaw,g722
outbound_auth=hcloud-auth
aors=hcloud
from_domain=VOTRE-DOMAINE
dtmf_mode=rfc4733
Appels sortants dans votre plan de numérotation :
exten => _0XXXXXXXXX,1,Dial(PJSIP/${EXTEN}@hcloud)
exten => _00.,1,Dial(PJSIP/${EXTEN}@hcloud)
Appels entrants : contexte from-hcloud, le numéro appelé est dans ${EXTEN}.
Vérifiez l’enregistrement : asterisk -rx "pjsip show registrations" doit afficher Registered.
FreePBX
Connectivité › Trunks › Ajouter un trunk SIP (chan_pjsip) :
| Onglet | Champ | Valeur |
|---|---|---|
| Général | Nom du trunk | hcloud |
| pjsip Settings › General | Username / Secret | Identifiant / mot de passe |
| Authentication / Registration | Outbound / Send | |
| SIP Server / Port | Votre serveur / 5070 |
|
| pjsip Settings › Advanced | From Domain | Votre domaine |
| DTMF Mode | RFC 4733 |
Puis une route sortante qui utilise ce trunk, et des routes entrantes (DID = vos numéros) vers vos postes, files ou SVI.
Dépannage
| Symptôme | Vérification |
|---|---|
| Pas enregistré | Port 5070, domaine exact, mot de passe sans espace |
| Appels sortants refusés | Format du numéro (national ou international), droits, appels simultanés |
| Appels entrants absents | Routes entrantes (DID) ; numéro de secours ; trunk bien enregistré |
| Pas de son | Ports RTP du PBX ouverts ; NAT : external_media_address et external_signaling_address renseignés |
Mis à jour le 30 octobre 2026 · Une question ? Contactez-nous