I'm traying to create a user from postman in Standalone distribution:

I try with

Post to: http://localhost:9080/syncope/rest/users

Body (JSON from the http://localhost:9080/syncope/swagger/):

{
  "@class": "org.apache.syncope.common.lib.to.UserTO",
  "realm": "/",
  "auxClasses": [
    "string"
  ],
  "plainAttrs": [
    {
      "schema": "string",
      "values": [
        "string"
      ]
    }
  ],
  "derAttrs": [
    {
      "schema": "string",
      "values": [
        "string"
      ]
    }
  ],
  "virAttrs": [
    {
      "schema": "string",
      "values": [
        "string"
      ]
    }
  ],
  "resources": [
    "string"
  ],
  "username": "string",
  "password": "string",
  "securityQuestion": "string",
  "securityAnswer": "string",
  "roles": [
    "string"
  ],
  "privileges": [
    "string"
  ],
  "relationships": [
    {
      "type": "string",
      "otherEndType": "string",
      "otherEndKey": "string",
      "otherEndName": "string"
    }
  ],
  "memberships": [
    {
      "groupKey": "string",
      "groupName": "string",
      "plainAttrs": [
        {
          "schema": "string",
          "values": [
            "string"
          ]
        }
      ],
      "derAttrs": [
        {
          "schema": "string",
          "values": [
            "string"
          ]
        }
      ],
      "virAttrs": [
        {
          "schema": "string",
          "values": [
            "string"
          ]
        }
      ]
    }
  ]
}

But the response is:

{
    "status": 400,
    "type": "RequiredValuesMissing",
    "elements": [
        "surname",
        "fullname",
        "userId"
    ]
}

I try to add it but the request header throw a x-application-error-info
says:

Unknown:UnrecognizedPropertyException: Unrecognized field "surname" (class
org.apache.syncope.common.lib.to.UserTO), not marked as ignorable

Reply via email to