Multiple JSON fields can be defined within a single JSON attribute. For any source attribute that does not exist, the corresponding JSON field is omitted from the JSON attribute. The following code demonstrates the mapping of a standard LDAP schema into the standard PingOne user schema.

dsconfig create-attribute-map \
  --map-name PingDirectory_to_PingOne_User_Map

...

dsconfig create-attribute-mapping \
  --map-name PingDirectory_to_PingOne_User_Map \
  -mapping-name name \
  --type json

dsconfig create-json-attribute-mapping-field \
  --map-name PingDirectory_to_PingOne_User_Map \
  --mapping-name name \
  --field-name formatted \
  --set from-attribute:cn \
  --json-type string

dsconfig create-json-attribute-mapping-field \
  --map-name PingDirectory_to_PingOne_User_Map \
  --mapping-name name \
  --field-name given \
  --set from-attribute:givenName \
  --json-type string

dsconfig create-json-attribute-mapping-field \
  --map-name PingDirectory_to_PingOne_User_Map \
  --mapping-name name \
  --field-name family \
  --set from-attribute:sn \
  --json-type string