cancel
Showing results for 
Search instead for 
Did you mean: 

about UnboundID SCIM 1.8

prasad
New Member
0 Kudos

about UnboundID SCIM 1.8

Hello

I am trying to connect to some target systems by using “unboundID scim SDK 1.8.12”. I am able to connect some target systems like “UnboundID scim server” but stuck when trying to connect salesforce.

I able to retierve all users from saleforce but when try to retirve schema from saleforce it failed with exception

“com.unboundid.scim.sdk.InvalidResourceException: Resource 'Schema' is malformed: Sub-attribute subAttributes is not defined for attribute urn:scim:schemas:core:1.0:subAttributes]”

Bello is my code snippet to get schema

 

  */

    public void discoverSchema() throws ConnectorException {

        Schema schema = null;

        SCIMService svc = createService();

 

        SCIMEndpoint<ResourceDescriptor> schemaEndpoint =

            svc.getResourceSchemaEndpoint();

        try {

            Resources<ResourceDescriptor> resources = schemaEndpoint.query(null);

            Iterator<ResourceDescriptor> it = resources.iterator();

                 //logic to put in database

 

} catch (SCIMException e) {

            throw new ConnectorException(e);

        }

    }

 

*/

 

 

 

 

I am using scim-sdk-1.8.12.jar.

 

According to my analysis it seems like  failed at manager’s sub-attribute in extension model. extension model structure shown bellow

 

 

//////////////////////////////////////////////////////////////////////////////////////////////////////

          "name": "urn:scim:schemas:extension:enterprise:1.0",

          "type": "complex",

          "multiValued": false,

          "description": "Scim Enterprise extensions",

          "schema": "urn:scim:schemas:extension:enterprise:1.0",

          "readOnly": false,

          "required": true,

          "subAttributes": [

            {

              "name": "organization",

              "type": "string",

              "description": "The organization the user belongs to",

              "readOnly": true,

              "required": true,

              "caseExact": false

            },

            {

              "name": "employeeNumber",

              "type": "string",

              "description": "The employee number of the user",

              "readOnly": false,

              "required": false,

              "caseExact": false

            },

            {

              "name": "division",

              "type": "string",

              "description": "The division of the user",

              "readOnly": false,

              "required": false,

              "caseExact": false

            },

            {

              "name": "department",

              "type": "string",

              "description": "The department of the user",

              "readOnly": false,

              "required": false,

              "caseExact": false

            },

            {

             "name": "manager",

              "type": "complex",

              "description": "The manager of the user",

              "readOnly": false,

              "required": false,

              "caseExact": false,

              "subAttributes": [

                {

                  "name": "managerId",

                  "type": "string",

                  "description": "The id of the manager user",

                  "readOnly": false,

                  "required": false,

                  "caseExact": false

                },

                {

                  "name": "displayName",

                  "type": "string",

                  "description": "The display name of the manager user",

                  "readOnly": true,

                  "required": false,

                  "caseExact": false

                }

              ]

            }

///////////////////////////////////////////////////////////////////

 

 

 

Is I done something wrong in code?

 

you can find full jeson response get from manage system on bellow link 

Json response

 

Thanks and regards 

Prasad Parab

2 REPLIES
UnboundID subrata
UnboundID
0 Kudos

Re: about UnboundID SCIM 1.8

Definutely the Manager schema is not one that is supported by SCIM 1.1.

 

Look at http://www.simplecloud.info/specs/draft-scim-core-schema-01.html#schema_structure section 10 "Resource Schema". subAttributes within a atribute does not support the next level of subAttributes. Attributes of subAttribute are:

subAttributesA list specifying the contained attributes. OPTIONAL.

name
The attribute's name.
type
The attribute's data type; e.g., String.
description
The attribute's human readable description. When applicable Service Providers MUST specify the description specified in the core schema specification.
readOnly
A Boolean value that specifies if the attribute is mutable.
required
A Boolean value that specifies if the attribute is required.
caseExact
A Boolean value that specifies if the String attribute is case sensitive.
canonicalValues
A collection of canonical values. When applicable Service Providers MUST specify the canonical types specified in the core schema specification; e.g.,"work","home". OPTIONAL.

 

 

 

 

prasad
New Member
0 Kudos

Re: about UnboundID SCIM 1.8

I went trough section 10  of SCIM 1.1 and it states "Unlike other core Resources the schema Resource MAY contain a complex object within a Sub-Attribute and all Attributes are REQUIRED unless other specified.

 

Going by the above what salesforce returns for manage subattribute adheres to SCIM1.1 documentation. I think the sdk should consider processing such complex subattributes. 

Labels