External Integrations & Webhooks¶
Complete reference for all external API and webhook configurations required for the Odoo 15 ERP system.
Quick Reference¶
| Integration | Odoo Setting Location | External Portal |
|---|---|---|
| Xero | Accounting > Configuration > Xero | developer.xero.com |
| JustCall SMS | Settings > JustCall SMS > Configuration | justcall.io |
| Google Chat | Settings > Google Chat | Google Chat Spaces |
| reCAPTCHA | .env file |
google.com/recaptcha |
| REST API OAuth | Settings > Technical > OAuth | N/A |
Domain Configuration¶
When changing your production domain, update all integrations below.
Current Production Domains¶
| Service | Domain | Purpose |
|---|---|---|
| Odoo ERP | erp.austinjdx.com |
Main ERP system |
| Landing Page | austinjdx.com |
Public website |
| Field PWA | service.austinjdx.com |
Field technician app |
| Documentation | docs.austinjdx.com |
This documentation |
Xero Integration¶
Xero accounting integration for invoice synchronization.
Odoo Configuration¶
Location: Accounting > Configuration > Xero Connections
| Field | Description | Example Value |
|---|---|---|
| Connection Name | Display name | Production Xero |
| Company | Odoo company | Your Company |
| Client ID | From Xero portal | ABC123... |
| Client Secret | From Xero portal | secret... |
| Redirect URI | OAuth callback URL | https://erp.austinjdx.com/xero/callback |
| Webhook Key | Signature verification | webhook-key... |
| Down Payment Product | Product for DP detection | Down Payment |
| Payment Journal | Bank/cash journal | Bank |
| Sales Account Code | Xero sales account | 400 |
| Deposit Account Code | Xero deposit account | 835 |
Xero Developer Portal¶
URL: https://developer.xero.com/app/manage
| Setting | Value |
|---|---|
| Redirect URI | https://erp.austinjdx.com/xero/callback |
| Webhook URL | https://erp.austinjdx.com/xero/webhook |
Webhook Events¶
Configure these webhook events in Xero:
INVOICE.UPDATED- Payment notifications
Troubleshooting¶
| Issue | Solution |
|---|---|
| OAuth redirect error | Verify Redirect URI matches exactly in both Odoo and Xero portal |
| Webhook not receiving | Check webhook URL is accessible from internet |
| Token expired | Click "Disconnect" then "Connect to Xero" to re-authorize |
JustCall SMS¶
SMS/MMS integration with unified inbox and multi-line support.
Odoo Configuration¶
Location: Settings > JustCall SMS > Configuration
| Field | Description | Example Value |
|---|---|---|
| API Key | From JustCall dashboard | your-api-key |
| API Secret | From JustCall dashboard | your-api-secret |
| Webhook Base URL | Public URL for webhooks | https://erp.austinjdx.com |
| Webhook Secret | Optional signature verification | your-secret |
| Default Line | Default line for sending | Sales Line |
JustCall Dashboard¶
URL: https://app.justcall.io/settings/webhooks
| Setting | Value |
|---|---|
| Webhook URL | https://erp.austinjdx.com/justcall/webhook/sms |
Webhook Events¶
Configure these events in JustCall:
| Event | Description |
|---|---|
sms.received |
Incoming SMS messages |
sms.sent |
Outgoing SMS confirmation |
sms.delivered |
Delivery status updates |
Phone Lines¶
Location: Settings > JustCall SMS > Phone Lines
| Field | Description | Example |
|---|---|---|
| Name | Display name | Sales Line |
| Phone | Number (E.164 without +) | 15125551234 |
| Type | Line purpose | sales / support / operations |
| Is Default | Default for sending | True/False |
Troubleshooting¶
| Issue | Solution |
|---|---|
| Webhook not receiving | Check URL: curl https://erp.austinjdx.com/justcall/webhook/test |
| SMS not matching partners | Run: env['justcall.sms'].action_match_all_partners() |
| Missing messages | Run manual sync: env['justcall.sms'].sync_from_api(hours=48) |
Google Chat¶
Team notifications to Google Chat spaces.
Odoo Configuration¶
Location: Settings > Google Chat
| Field | Description | Example Value |
|---|---|---|
| Company | Odoo company | Your Company |
| Webhook URL | From Google Chat space | https://chat.googleapis.com/v1/spaces/... |
| Enable FSM Notifications | FSM stage changes | True |
| Enable Sales Notifications | Sales order confirmations | True |
| Enable Invoice Notifications | Invoice posting | True |
| Enable PO Notifications | Purchase order confirmations | True |
Google Chat Space Setup¶
- Open Google Chat space
- Click Space name > Apps & integrations > Webhooks
- Click Add webhook
- Name it (e.g., "Odoo Notifications")
- Copy the webhook URL
- Paste into Odoo configuration
No Domain Dependency
Google Chat webhooks are URLs FROM Google. They don't depend on your Odoo domain and don't need updating when you change domains.
Notification Events¶
| Event | Trigger |
|---|---|
| FSM Stage Change | FSM order moves to new stage |
| Sales Confirmation | Sale order confirmed |
| Invoice Posted | Customer invoice posted |
| PO Confirmation | Purchase order confirmed |
reCAPTCHA¶
Google reCAPTCHA v3 for spam protection on landing page forms.
Environment Configuration¶
File: .env (production server)
Google reCAPTCHA Console¶
URL: https://www.google.com/recaptcha/admin
| Setting | Value |
|---|---|
| reCAPTCHA Type | v3 |
| Domains | austinjdx.com, erp.austinjdx.com |
Adding New Domains¶
When changing domains:
- Go to reCAPTCHA Admin Console
- Select your site
- Click Settings (gear icon)
- Add new domain to "Domains" list
- Save changes
REST API OAuth Clients¶
OAuth2 clients for external application integrations.
Odoo Configuration¶
Location: Settings > Technical > OAuth > Applications
| Field | Description |
|---|---|
| Name | Application name |
| Client ID | Generated automatically |
| Client Secret | Generated automatically |
| Redirect URIs | Allowed callback URLs |
| Scopes | Permissions granted |
Creating OAuth Client¶
- Go to
Settings > Technical > OAuth > Applications - Click Create
- Enter application name
- Add redirect URIs (one per line)
- Save to generate Client ID and Secret
API Key Authentication¶
Location: Settings > Users > [User] > Preferences > API Keys
- Select user
- Go to Preferences tab
- Under API Keys, click New API Key
- Enter description
- Click Generate Key
- Copy key (shown only once)
Domain Migration Checklist¶
When migrating to a new domain (e.g., austinjdx.com to erp.austinjdx.com):
1. Update .env File¶
# Update domain settings
DOMAIN_ERP=erp.austinjdx.com
DOMAIN_LANDING=austinjdx.com
DOMAIN_PWA=service.austinjdx.com
DOMAIN_DOCS=docs.austinjdx.com
2. SSL Certificates¶
3. External Integrations¶
- Xero Developer Portal
- Update Redirect URI
- Update Webhook URL
- Xero in Odoo
- Update Redirect URI field
- Reconnect to Xero (Disconnect → Connect)
- JustCall Dashboard
- Update Webhook URL
- JustCall in Odoo
- Update Webhook Base URL
- reCAPTCHA Console
- Add new domain to allowed list
- OAuth Clients
- Update redirect URIs for any external apps
4. DNS Configuration¶
Ensure DNS records point to your server:
| Record | Type | Value |
|---|---|---|
erp.austinjdx.com |
A | Your server IP |
service.austinjdx.com |
A | Your server IP |
docs.austinjdx.com |
A | Your server IP |
5. Verify Configuration¶
# Check nginx config
./production_deploy.sh configure-nginx
# Restart services
./production_deploy.sh restart
# Test endpoints
curl -I https://erp.austinjdx.com
curl -I https://erp.austinjdx.com/xero/callback
curl -I https://erp.austinjdx.com/justcall/webhook/test
Webhook Endpoints Reference¶
All webhook endpoints exposed by the Odoo ERP:
| Endpoint | Method | Integration | Purpose |
|---|---|---|---|
/xero/callback |
GET | Xero | OAuth2 callback |
/xero/webhook |
POST | Xero | Payment notifications |
/justcall/webhook/sms |
POST | JustCall | Incoming SMS |
/justcall/webhook/test |
GET | JustCall | Webhook connectivity test |
Security Best Practices¶
- Use HTTPS - All webhook URLs must use HTTPS
- Webhook Secrets - Configure signature verification where available
- API Key Rotation - Rotate API keys periodically
- Minimal Permissions - Create dedicated API users with limited access
- Monitor Logs - Check webhook logs for unusual activity
Troubleshooting¶
Webhook Not Receiving Data¶
# Check webhook is accessible
curl -X POST https://erp.austinjdx.com/justcall/webhook/sms \
-H "Content-Type: application/json" \
-d '{"test": true}'
# Check Odoo logs
docker compose logs odoo | grep -i webhook
OAuth Redirect Errors¶
- Verify redirect URI matches EXACTLY (including trailing slash)
- Check HTTPS certificate is valid
- Ensure domain is accessible from external service