User invitation emails not sending from partner portal after Azure AD B2B setup

New partner users added to our Dynamics 365 portal are not receiving invitation emails after we configured Azure AD B2B authentication. We recently migrated from local authentication to Azure AD B2B to improve security and enable single sign-on for our partner network.

The partner portal is properly configured and existing users who were migrated can log in successfully using their Azure AD credentials. However, when we create new portal contacts and send invitations, the users never receive the invitation emails. We’ve verified email addresses are correct and checked spam folders. The portal contact records show status as ‘Invitation Pending’ but emails are not being delivered.

We’ve confirmed Azure AD B2B invitation settings allow external users and our domain is not blocked. Portal notification configuration appears standard with the default email templates enabled. This is preventing us from onboarding 15 new partner companies this month, affecting our partner expansion goals. Has anyone successfully configured invitation emails with Azure AD B2B integration for Dynamics 365 portals?

Excellent troubleshooting! Since you’ve resolved the immediate issue, let me provide comprehensive guidance on all three focus areas to ensure your Azure AD B2B portal integration remains reliable.

Azure AD B2B Invitation Settings - Complete Configuration:

For successful portal user invitations with Azure AD B2B, you need multiple configuration layers properly aligned:

  1. External Collaboration Settings (Azure AD):

    • Navigate: Azure Portal > Azure Active Directory > External Identities > External collaboration settings
    • Guest user access: Set to ‘Guest users have limited access to properties and memberships of directory objects’
    • Guest invite settings: Select ‘Admins and users in the guest inviter role can invite’
    • Collaboration restrictions: Ensure partner domains are not in the deny list
    • Enable guest self-service sign up: Set to ‘Yes’ for automated invitation flows
  2. Application Registration Permissions:

    • Navigate: Azure Portal > App registrations > [Your D365 Portal App] > API permissions
    • Required Microsoft Graph permissions:
      • User.Invite.All (Application permission) - This was your missing piece
      • User.Read.All (Application permission) - For reading user profiles
      • Directory.Read.All (Delegated permission) - For directory queries
    • After adding permissions, click ‘Grant admin consent for [tenant]’
    • Verify consent status shows green checkmarks for all permissions
  3. Service Principal Configuration:

    • Ensure the app registration has a valid client secret or certificate
    • Navigate to Certificates & secrets and verify expiration dates
    • If expired, generate new secret and update Dynamics portal configuration
    • Document secret expiration dates and set calendar reminders for renewal
  4. Enterprise Application Settings:

    • Navigate: Azure Portal > Enterprise Applications > [Your D365 Portal App]
    • Verify ‘User assignment required’ matches your security requirements
    • Check ‘Users and groups’ tab to confirm expected access levels

Portal Notification Configuration - Email Delivery Setup:

The portal notification system requires proper configuration to work with Azure AD B2B:

  1. Site Settings Verification:

    • Navigate: Portal Management > Website > Site Settings
    • Key settings to verify:
      • Authentication/Registration/InvitationEnabled = true
      • Authentication/Registration/RedemptionEnabled = true
      • Authentication/Registration/InvitationEmailTemplate = [template ID]
      • EmailSender/DefaultFromEmailAddress = valid sender address
    • Create missing settings if they don’t exist
  2. Email Template Configuration:

    • Navigate: Portal Management > Email Templates
    • Find ‘Invitation’ template (or create if missing)
    • Template must include:
      • {{InvitationUrl}} token for redemption link
      • {{OrganizationName}} for personalization
      • Clear instructions for first-time login
      • Support contact information
    • Test template rendering with sample data
  3. Email Provider Setup:

    • Verify SMTP configuration or email provider integration
    • Navigate: Settings > Email Configuration
    • Test email delivery with ‘Send Test Email’ function
    • Check email deliverability and SPF/DKIM records for your domain
    • Monitor email logs for failed delivery attempts
  4. Invitation Workflow:

    • When creating portal contacts, ensure ‘Send invitation’ option is checked
    • Verify contact email addresses are valid and properly formatted
    • Check that contact’s ‘Web Authentication’ is set appropriately
    • Confirm invitation status updates to ‘Invitation Sent’ after processing

Audit Log Review - Troubleshooting and Monitoring:

Implement comprehensive logging to catch future issues early:

  1. Azure AD Audit Logs:

    • Navigate: Azure Portal > Azure Active Directory > Audit logs
    • Filter by Activity: ‘Invite external user’
    • Check Status: Look for ‘Success’ vs ‘Failure’ entries
    • Review failure reasons: Common issues include:
      • Insufficient permissions
      • Invalid email format
      • Domain restrictions
      • Rate limiting (too many invitations)
    • Set up alerts for invitation failures
  2. Dynamics Portal Diagnostics:

    • Enable diagnostic logging in Portal Management
    • Navigate: Settings > Portal > Diagnostic Logging
    • Set logging level to ‘Verbose’ temporarily for troubleshooting
    • Review logs for:
      • Authentication errors
      • Email sending failures
      • Template rendering issues
      • API call failures to Azure AD
  3. Application Insights Integration:

    • Connect your portal to Azure Application Insights
    • Monitor invitation email metrics:
      • Invitation creation rate
      • Email delivery success rate
      • Time to invitation redemption
      • Failed login attempts after invitation
    • Create custom dashboards for partner onboarding KPIs
  4. Regular Health Checks:

    • Weekly verification of:
      • App registration client secret expiration (renew 30 days before expiry)
      • Email template functionality
      • Sample invitation test to dummy account
      • Azure AD permission status
    • Monthly review of:
      • Invitation acceptance rates
      • Bounced email patterns
      • Partner onboarding completion times

Additional Best Practices for Your Scenario:

  1. Bulk Partner Onboarding:

    • For your 15 new partner companies, create a standardized process:
      • Prepare contact records in advance with validated email addresses
      • Schedule invitation sends in batches to avoid rate limiting
      • Track invitation status in a monitoring dashboard
      • Follow up on unredeemed invitations after 48 hours
  2. Communication Plan:

    • Send advance notification to partners about incoming invitations
    • Provide instructions document with screenshots of redemption process
    • Include troubleshooting steps for common issues (spam folder, link expiration)
    • Establish support channel for invitation-related questions
  3. Security Considerations:

    • Implement conditional access policies for external users
    • Require MFA for partner portal access
    • Set invitation link expiration policy (default 7 days, consider extending to 30 days for partners)
    • Monitor for suspicious invitation patterns or unauthorized access attempts
  4. Documentation and Training:

    • Document your complete B2B invitation configuration
    • Create runbook for common troubleshooting scenarios
    • Train additional team members on invitation management
    • Maintain contact list for Azure AD and portal administrators

With these comprehensive configurations and monitoring practices, your partner portal invitation system should operate reliably. The combination of proper Azure AD permissions, portal notification setup, and proactive audit log review will prevent most common issues and enable quick resolution when problems do occur.


This draft is based on general Microsoft Dynamics 365 Sales knowledge. It has not been verified against your specific version and environment. Practitioners: verify the steps and share your experience below.

When using Azure AD B2B with Dynamics portals, invitation emails are sent from Azure AD, not from Dynamics. Check your Azure AD external collaboration settings - there’s a specific permission that controls whether invitation emails are sent. Navigate to Azure Portal > Azure Active Directory > External Identities > External collaboration settings and verify ‘Enable guest self-service sign up via user flows’ is enabled and ‘Admins and users in the guest inviter role can invite’ is set to Yes.

I checked the Azure AD settings and both options you mentioned are enabled. The guest inviter permissions look correct. Is there a specific role assignment needed for the service account that Dynamics uses to send these invitations? I’m wondering if it’s an authentication or permissions issue between Dynamics and Azure AD.

Yes, the Dynamics 365 application registration in Azure AD needs the ‘User.Invite.All’ permission to send B2B invitations on behalf of users. Go to Azure Portal > App registrations > find your Dynamics 365 app > API permissions and verify this permission is granted. If it’s missing, add it and grant admin consent. After adding the permission, it can take up to 30 minutes for changes to propagate. Also check if the app registration has a valid client secret that hasn’t expired.

Beyond Azure AD permissions, check your portal’s email configuration. Even with Azure AD B2B, the portal needs proper SMTP settings or an email provider configured to handle the invitation workflow. Navigate to Portal Management > Website > Site Settings and verify the ‘Authentication/Registration/InvitationEnabled’ setting is set to true. Also check if there’s a custom email template configured that might be malformed or missing required tokens. The default Azure AD B2B invitation uses a specific template format.

Found it! The ‘User.Invite.All’ permission was missing from our app registration. I added it and granted admin consent as suggested. I also verified the site settings and the invitation enabled flag was correctly set to true. I just tested with a new partner user and they received the invitation email within minutes. Thank you all for the guidance!

I also verified the site settings and the invitation enabled flag was correctly set to true.