Loading

Account Manager Infrastructure Upgrade: Guide to Upcoming Breaking Changes on B2C Commerce

Date de publication: Aug 25, 2026
Description

Who Is Impacted?

If your organization uses an OAuth 2.0 client to authenticate with Account Manager, prepare for changes in token expiration behavior and API response formats. This guide outlines these upcoming changes and provides clear, actionable steps to help your team prepare and update your integration seamlessly.

 

Key Dates

These changes take effect with the release of Account Manager in March 2027. Please review the details below and complete any necessary updates before this date.

Résolution

Summary of Breaking Changes & Action Required

What's ChangingWho's AffectedAction Required
1Authentication failures on Resource Owner Password now return HTTP 400 instead of 401Clients that check specifically for status code 401 to detect authentication failureUpdate conditional checks to treat HTTP 400 as an authentication failure
2Non-offline refresh tokens invalidate after 30 minutes of inactivity (legacy 1-day override removed)Batch jobs, background services, and test frameworks that don't request scope=offline_access and assume long idle validityAdd scope=offline_access for long-running tasks, or handle HTTP 400 invalid_grant by re-authenticating
3Empty address claims are omitted from UserInfo/ID tokens instead of returned as {}Clients that check for the presence of the address key to determine whether the address scope was grantedCheck the scope claim on the token instead of relying on response keys; treat a missing key and empty fields identically

 

1. Authentication Failures Will Return HTTP Status 400 (Bad Request) Instead of 401

When a client submits invalid credentials during a Resource Owner Password, the HTTP status code will now be 400 Bad Request (previously 401 Unauthorized). The error response body remains unchanged (error: "invalid_grant"). This update brings the endpoint into full compliance with the standard OAuth 2.0 specification (RFC 6749).

Impacted Clients: This change affects any client application or service that specifically checks for HTTP status code 401 to detect authentication failure. If your code expects 401, it may treat an invalid credential response as an unexpected generic error.

Action Required: Review your code and error handling logic. Update any conditional checks for credential failures so that HTTP status code 400 is recognized as an authentication failure.

 

2. Non-Offline Refresh Tokens Now Invalidate After 30 Minutes of Inactivity

Account Manager will strictly enforce SSO session idle limits for non-offline refresh tokens (30 minutes by default). The legacy per-client override that extended idle lifetimes to 1 day is being removed. Integrations requiring persistent, long-lived refresh tokens across long periods of inactivity must explicitly request scope=offline_access.

Key Differences:

  • Previously: Non-offline refresh tokens received extended expiration times during issuance and refresh calls, remaining active longer than the SSO session idle window.
  • Going forward: Non-offline refresh token expiration will be strictly tied to the realm's SSO session idle timeout (30 minutes by default). Once the SSO session idles out, the refresh token can no longer be used.

Impacted Clients: This change affects applications using Resource Owner Password (direct grant) or Authorization Code flows that do not request scope=offline_access and assume tokens remain valid during extended idle intervals. Common scenarios include:

  • Batch or automation jobs that authenticate once and refresh tokens over long periods.
  • Background services linked to an interactive user session.
  • Automated test frameworks that acquire a token, delay execution, and attempt to refresh later.

Note: Integrations that already request offline_access are unaffected. Offline refresh tokens will continue to use the realm's designated offline session settings.

Expected Behavior & Observations:

  • Non-offline refresh tokens returned by the token endpoint will reflect a shorter expiration time aligned with the 30-minute idle window.
  • If an application remains idle for more than 30 minutes before attempting to use the refresh token (long-running batch jobs, infrequent automation flows), the request will fail with HTTP 400 invalid_grant.
  • The expires_in field returned during token refresh calls will match the shorter duration.
  • Token introspection requests (.../protocol/openid-connect/token/introspect) will report the updated shorter expiration.
  • Calls to refresh tokens after the idle period elapses will return an error, requiring re-authentication.

Action Required:

  1. For long-running tasks: Add scope=offline_access to your initial authorization request. This provides a long-lived offline refresh token that remains valid across extended idle periods (typically 1+ days).
  2. For standard sessions: If long idle refresh functionality isn’t required, no immediate code changes are necessary. Ensure your client application gracefully handles HTTP 400 invalid_grant errors by initiating re-authentication.

 

3. Omission of Empty Address Claims in UserInfo and ID Tokens

To align with standard OpenID Connect specifications, the address claim will no longer be included in UserInfo/ID token responses if all address fields for the user are empty. Previously, Account Manager returned "address": {} in these scenarios.

Key Differences: When the address scope was granted but all address fields (street_address, locality, region, postal_code, country, formatted) were empty/null, Account Manager previously returned an empty object ("address": {}) on the UserInfo endpoint (.../protocol/openid-connect/userinfo) and ID tokens. Under the updated behavior:

  • If at least one address field is populated: The address claim is returned containing only non-null fields.
  • If all address fields are empty: The address claim is omitted entirely from the JSON payload.

Response Payload Comparison: For users with no address on file:

// Before
{
  "sub": "...",
  "address": {}
}

// After
{
  "sub": "..."
}

For users with a partially populated address, the response is unchanged — only truly empty addresses are affected.

Impacted Clients: This change affects any application that checks for the presence of the address key in the response payload to determine if the address scope was granted. Applications using this logic might mistakenly assume the scope was denied when querying a user with no address on file.

Action Required:

  1. Scope Validation: Inspect the scope claim on the access token or the token endpoint response to verify granted scopes, rather than relying on response keys.
  2. Data Handling: Update application logic to treat both a missing address key and individual null fields identically as empty address data.
Numéro d’article de la base de connaissances

005393367

 
Chargement
Salesforce Help | Article