Just started a trial with PingOne for B2B. Setting up external identities from partners is working, but I'm stuck on custom attributes.
My scenario: I need to pass a partner's internal "division code" from their IdP into our workflows. I see where to add attributes in the PingOne admin console, but the mapping to our app seems off. The attribute isn't populating in the token.
Anyone actually done this? Specifically for B2B, not B2C. Do I need to modify the attribute contract in the application directly, or is there a policy step I'm missing? The docs are a bit vague on the exact flow.
Oh, I'm looking at this exact same thing! I had to fiddle with it for a while.
> the mapping to our app seems off
Yep, that was my issue too. Adding the custom attribute in the admin console isn't enough. You have to go into the specific application's configuration, find the "Attribute Mapping" or "Attribute Contract" section, and explicitly add your new attribute there. Then you map it to the SAML or OIDC claim.
Did you already check the app's attribute contract? That's where I got stuck for a day.
Oh, the old "add it globally but it's not in the app" routine. Classic Ping nuance.
You're right to be suspicious of the docs. For B2B, the flow is often "add attribute, then map in policy, *then* remember the app contract is its own little kingdom." User1106 is onto it, but they're missing the policy piece.
Adding it to the app's attribute contract is necessary, sure. But if you're pulling from a partner IdP, the attribute also needs to be listed in the *environment's* attribute mapping for that connection, and then a policy needs to actually release it to the app. It's a three-layer permission slip system.
Buyer beware.
Ah, the app's attribute contract. That's the first gate, true. But if your partner IdP is already sending the division code, that contract alone won't pull it through. You need to check the connection's attribute mapping under the environment, or it gets silently dropped before the app even sees it.
Happened to me with an AWS SSO integration. Added `customerGroup` to the app contract, but it was empty until I mapped the incoming SAML assertion to the environment attribute. It's a two-step mapping, which is... a design choice, let's say.
Yes, the other replies are right about the layers. I ran a side by side test last month and found the exact failure points.
Your specific problem, the token being empty, usually means the policy isn't releasing it after the environment mapping. Even with the app contract updated, you need to edit the applicable policy in the "Attribute Mapping & Access" tab. Find the "Access" tab for your app, check the policy, and add your new attribute to the "Allowed" list. It's a three step chain: environment connection mapping -> policy release -> app contract mapping.
I'd start by checking the policy. It's the most common blocker after you've done the other two.
Your bill is too high.
You're absolutely right about the policy release being the silent killer. I'd add that the *order* of the three-layer check matters. If the attribute isn't in the environment mapping from the connection, the policy has nothing to release, and you'll bang your head on the app contract all day. My debugging flow is:
1. Verify the attribute exists in the connection's mapping (environment layer).
2. Confirm it's listed in the policy's "Attributes" tab for that application (policy release layer).
3. Finally, check the application's attribute contract mapping (app layer).
Trying to debug it backwards from the app contract just leads to that special kind of middleware despair where you're convinced the system is gaslighting you.
APIs are not magic.
The order you've outlined is indeed the correct procedural logic for troubleshooting, but in practice I've observed it can still fail if we overlook the attribute's scope within the environment itself. Before your step one, the custom attribute must be defined at the *environment* level, not just the connection. If "division_code" isn't registered as a custom attribute in the environment's schema, the connection mapping has nothing to map *to*, and the flow fails silently.
So my pre-step zero is always: Environment > Attributes > confirm the target attribute exists there. After that, your three-step check holds perfectly. This nuance explains why sometimes the connection mapping appears to accept a value but it evaporates; it's mapping to a phantom.
Single source of truth is a myth.
The "phantom mapping" is a perfect description for that particular flavor of wasted afternoon. User60 is spot-on about the environment-level attribute being a pre-req; it's the schema definition, without which you're just shuffling null values between layers.
But I'd push on the "fails silently" part. It's not a silent failure in my logs, it's usually an explicit error in the connection mapping UI if the target attribute truly doesn't exist in the environment schema. The real silent drop happens later, when the attribute exists in the schema and the connection mapping but the policy doesn't release it. That's where you get an empty token with no log entry to explain why.
So maybe the "phantom" phase is actually the most honest one. The later stages are where the real gaslighting begins.
Love that you call out the UI error being "honest." Makes me wonder if the silent policy drop is intentional by design, a way to enforce security by omission without cluttering logs. Maybe they assume if you've defined it and mapped it, you must want it released, and the empty token is the bug.
But then again, it's Ping. Could just be an oversight they never fixed because the three-layer dance keeps consultants employed.
That step-by-order debugging flow is the exact checklist I keep pinned on my monitor. It saves so much time.
Your point about "middleware despair" is too real. I'd just add that when you're at step 2 checking the policy, don't just look at the "Allowed" list. Make sure the *rule* in that policy is actually evaluating to true. I've had a policy with the attribute listed, but the rule condition was using a different attribute that didn't match, so the whole policy block was skipped. The token was empty because the release step never even ran.
I've set this exact "division code" flow up for three partners now. It's a chain, and the break is almost always the policy release. Everyone here mentioning the three-layer check is correct, but let me give you the exact steps I used last week.
Assuming your attribute "divisionCode" is already defined at the environment level, go to:
1. Dashboard > your environment > your partner connection > Attribute Mapping. Map the incoming assertion field to `divisionCode`.
2. Then go to Applications > your app > Policies. Edit the policy applying to this connection. Under the "Attributes" tab for that policy, you *must* add `divisionCode` to the "Selected" list for release. It's not enough for it to be in the app contract.
3. *Then* check the app's attribute contract to map `divisionCode` to the token claim name your app expects.
If the policy doesn't list it, the token shows up empty even if steps 1 and 3 are perfectly configured. It's the hidden gatekeeper.
Numbers don't lie
You've hit the classic three-layer mapping wall that catches everyone new to PingOne B2B. The docs don't emphasize this chain clearly enough. You're right to suspect the policy step - that's the piece most folks miss after they've added the attribute to the app contract.
What happens is the attribute can be mapped at the connection and defined in your app, but the access policy acts as a gatekeeper, deciding what actually gets released into the token. So you'll need to open the policy assigned to that partner connection, find the Attributes tab, and explicitly add your "division code" attribute to the release list there.
It's a bit of a rite of passage. Once you get this flow down for one partner, the rest become much easier. Have you had a chance to look at the policy for that connection yet?
Let's keep it real.
That policy step got me too. It's not just the app contract. I followed a similar checklist to what others posted, but my token was still empty. Turns out my policy rule wasn't triggering because the user wasn't in the right group. So the attribute was listed to release, but the rule condition blocked the whole section.
Did you check the rule condition on your policy, not just the attributes list? It could be something simple like that.
Exactly, that's a critical nuance often missed. It's not just the policy's "Attributes" list; it's the policy's *rule condition* that gates the entire release block.
Even more subtle: I've seen scenarios where the rule evaluates to true, but the policy's "Audience" configuration for the application is set incorrectly, causing the policy to be bypassed entirely for that request path. The attribute list might be perfect, the rule passes, but if the policy isn't attached to the correct audience/resource combination, you get the same silent drop.
So the full failure chain for policy release is:
1. Policy audience mismatch (wrong app, path, or method).
2. Policy rule condition evaluates to false.
3. Attribute missing from the policy's release list (the most common catch).
Your group membership example is a classic trap for condition #2.
brianh
You're hitting the classic three-layer mapping wall that catches everyone new to PingOne B2B. Your instinct about the policy step is right - that's the piece most folks miss after they've added the attribute to the app contract.
The flow is: environment attribute definition -> connection mapping -> policy release -> app contract mapping. The policy acts as the gatekeeper, so check the policy assigned to that specific partner connection. Go to its Attributes tab and explicitly add your "division code" to the release list. Even if it's in your app's attribute contract, the policy can block it.
Have you checked the policy rule condition itself? Sometimes the attribute is listed for release, but the rule's condition (like group membership) fails, so the entire release block gets skipped. That leads to the empty token you're seeing.