We installed the Transaction Security Policy Accelerator in my org. We use Own and the daily backup schedule is triggering thousands of alerts for 'Detect API Access from Unapproved Third Party Apps' policy (We have the action configured to send email notifications). I am unable to configure an exclusion in the custom metadata 'Approved API Client' because I cannot obtain the client name in this case. Any guidance?
Hi Ajay,
Client and ConnectedAppId being blank here is expected, documented behavior for this call pattern — not something you're missing or misconfiguring.
- Client: "The service that executed the API event. If you're using an unrecognized client, this field returns 'Unknown' or a blank value."
- ConnectedAppId: populates only when the call goes through an OAuth 2.0 authentication process. A SOAP login()-based session (which is what your middleware is using with the Partner WSDL) doesn't go through OAuth, so this field is genuinely null for that auth pattern — there's no hidden client name to retrieve, because Salesforce never captured one for this login method.
So "Approved API Client" custom metadata, if it's keyed on ApiEvent.Client, structurally can't match this traffic — there's nothing populated to match against for a SOAP login-based integration user.
Practical fix: base the exclusion on the integration User instead of the API Client. Since your middleware authenticates as a dedicated integration user for this backup job, update your exclusion logic (or the Apex behind the TSP Accelerator's policy condition, if it's exposed for editing) to check ApiEvent.UserId/Username against an approved list, rather than Client/ConnectedAppId. This is the standard workaround for legacy SOAP login integrations specifically because Client/ConnectedAppId are documented as unreliable for that auth path.
Worth knowing for the medium term: Salesforce is moving away from SOAP login()-based API access generally — the "Allow any API Client" permission (used to let SOAP login calls bypass API Access Control) is being deprecated. If this integration can be migrated to an OAuth-based flow (Named Credential/External Client App using JWT Bearer or OAuth Client Credentials instead of SOAP login), ConnectedAppId would actually populate, and you'd get proper client-based governance going forward instead of working around a field that will never populate for this auth method.
Given this touches the TSP Accelerator's underlying policy logic, this is also worth raising directly with your Salesforce account team/Shield specialist — they can confirm the exact supported way to add a User-based exclusion within that specific Accelerator's metadata model, since the accelerator's custom metadata schema may need a field added rather than just a different value plugged into the existing one.