添加自定义 属性 的正确 SCIM 语法是什么

What is the proper SCIM syntax for adding a custom property

我正在尝试扩展用户模型并添加新字符串 属性。如果我理解,我可以简单地添加它和 return 值。

我的问题是如何在资源类型端点中对此进行记录。目前我们只有基本的 scim 实现,所以我们 return

"Resources": [
{
    "name": "User",
    "description": "User Accounts",
    "endpoint": "/Users",
    "schema": "urn:ietf:params:scim:schemas:core:2.0:User",
    "schemas": [
        "urn:ietf:params:scim:schemas:core:2.0:ResourceType"
    ],
    "id": "User",
   "meta": {
        "resourceType": "ResourceType",
        "location": "https://apidsw017086.docusignhq.com/v201411/scim/resourcetypes/user"
   }
}

我应该只添加属性部分并添加新属性,还是我还需要列出所有默认属性?

如整个规范中 RFC 7643 Section 3.3, you need to define a new schema and specify that schema in the ResourceType "schemaExtensions". You can look at the enterprise user schema extension 中所述,以获取如何执行此操作的示例。

示例资源类型表示:

[
    {
         "schemas": ["urn:ietf:params:scim:schemas:core:2.0:ResourceType"],
         "id": "User",
         "name": "User",
         "endpoint": "/Users",
         "description": "User Account",
         "schema": "urn:ietf:params:scim:schemas:core:2.0:User",
         "schemaExtensions": [
           {
             "schema": "urn:your:user:extension:schema",
             "required": false
           }
         ],
         "meta": {
           "location": "https://example.com/v2/ResourceTypes/User",
           "resourceType": "ResourceType"
         }
    }
]

示例资源模式表示:

[
    {
        "id": "urn:ietf:params:scim:schemas:core:2.0:User",
        "schemas": [ "urn:ietf:params:scim:schemas:core:2.0:Schema" ],
        "name": "User",
        "description": "User Account",
        "attributes": [ {...} ]
    },
    {
        "id": "urn:your:user:extension:schema",
        "schemas": [ "urn:ietf:params:scim:schemas:core:2.0:Schema" ],
        "name": "Your Custom User Extension Name",
        "description": "Your Custom User Extension Description",
        "attributes": [ {...} ]
    }
]