src/__fixtures__/json/api/schemas/user.json
{
"klass": "org.hisp.dhis.user.User",
"shareable": false,
"identifiableObject": true,
"relativeApiEndpoint": "/users",
"metadata": true,
"plural": "users",
"displayName": "User",
"collectionName": "users",
"apiEndpoint": "http://localhost:8080/dhis/api/users",
"nameableObject": false,
"defaultPrivate": false,
"name": "user",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"href": "http://localhost:8080/dhis/api/schemas/user",
"singular": "user",
"persisted": true,
"order": 101,
"translatable": false,
"references": [
"org.hisp.dhis.user.UserCredentials",
"org.hisp.dhis.organisationunit.OrganisationUnit",
"org.hisp.dhis.user.UserGroup",
"org.hisp.dhis.user.User"
],
"authorities": [
{
"type": "CREATE",
"authorities": ["F_USER_ADD", "F_USER_ADD_WITHIN_MANAGED_GROUP"]
},
{
"type": "DELETE",
"authorities": [
"F_USER_DELETE",
"F_USER_DELETE_WITHIN_MANAGED_GROUP"
]
}
],
"properties": [
{
"fieldName": "birthday",
"simple": true,
"required": false,
"writable": true,
"nameableObject": false,
"klass": "java.util.Date",
"propertyType": "DATE",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"cascade": "none",
"manyToMany": false,
"length": 255,
"collection": false,
"unique": false,
"name": "birthday",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "code",
"description": "The unique code for this Object.",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "IDENTIFIER",
"oneToOne": false,
"attribute": true,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 50,
"cascade": "none",
"manyToMany": false,
"length": 50,
"collection": false,
"unique": true,
"name": "code",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "access",
"simple": false,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "org.hisp.dhis.security.acl.Access",
"propertyType": "COMPLEX",
"oneToOne": false,
"attribute": false,
"owner": false,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"manyToMany": false,
"collection": false,
"unique": false,
"name": "access",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": false,
"manyToOne": false,
"constants": []
},
{
"fieldName": "education",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"cascade": "none",
"manyToMany": false,
"length": 2147483647,
"collection": false,
"unique": false,
"name": "education",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "gender",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 50,
"cascade": "none",
"manyToMany": false,
"length": 50,
"collection": false,
"unique": false,
"name": "gender",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "displayName",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": false,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"manyToMany": false,
"collection": false,
"unique": false,
"name": "displayName",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": false,
"manyToOne": false,
"constants": []
},
{
"fieldName": "publicAccess",
"simple": true,
"required": false,
"writable": true,
"min": 8,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": false,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 8,
"manyToMany": false,
"collection": false,
"unique": false,
"name": "publicAccess",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": false,
"manyToOne": false,
"constants": []
},
{
"fieldName": "jobTitle",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 160,
"cascade": "none",
"manyToMany": false,
"length": 160,
"collection": false,
"unique": false,
"name": "jobTitle",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "externalAccess",
"simple": true,
"required": false,
"writable": true,
"nameableObject": false,
"klass": "java.lang.Boolean",
"propertyType": "BOOLEAN",
"oneToOne": false,
"attribute": false,
"owner": false,
"readable": true,
"ordered": false,
"identifiableObject": false,
"manyToMany": false,
"collection": false,
"unique": false,
"name": "externalAccess",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": false,
"manyToOne": false,
"constants": []
},
{
"fieldName": "lastUpdated",
"description": "The date this object was last updated.",
"simple": true,
"required": false,
"writable": true,
"nameableObject": false,
"klass": "java.util.Date",
"propertyType": "DATE",
"oneToOne": false,
"attribute": true,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"cascade": "none",
"manyToMany": false,
"length": 255,
"collection": false,
"unique": false,
"name": "lastUpdated",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"relativeApiEndpoint": "/organisationUnits",
"fieldName": "teiSearchOrganisationUnits",
"simple": false,
"required": false,
"writable": true,
"collectionName": "teiSearchOrganisationUnits",
"min": 0,
"nameableObject": true,
"klass": "java.util.Set",
"propertyType": "COLLECTION",
"oneToOne": false,
"attribute": false,
"href": "http://localhost:8080/dhis/api/schemas/organisationUnit",
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": true,
"max": 2147483647,
"cascade": "none",
"manyToMany": true,
"collection": true,
"owningRole": "org.hisp.dhis.user.User.teiSearchOrganisationUnits",
"itemPropertyType": "REFERENCE",
"collectionWrapping": true,
"itemKlass": "org.hisp.dhis.organisationunit.OrganisationUnit",
"apiEndpoint": "http://localhost:8080/dhis/api/organisationUnits",
"unique": false,
"name": "teiSearchOrganisationUnit",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "surname",
"simple": true,
"required": true,
"writable": true,
"min": 2,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 160,
"cascade": "none",
"manyToMany": false,
"length": 160,
"collection": false,
"unique": false,
"name": "surname",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "employer",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 160,
"cascade": "none",
"manyToMany": false,
"length": 160,
"collection": false,
"unique": false,
"name": "employer",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "uid",
"description": "The Unique Identifier for this Object.",
"simple": true,
"required": false,
"writable": true,
"min": 11,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "IDENTIFIER",
"oneToOne": false,
"attribute": true,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 11,
"cascade": "none",
"manyToMany": false,
"length": 11,
"collection": false,
"unique": false,
"name": "id",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"relativeApiEndpoint": "/organisationUnits",
"fieldName": "organisationUnits",
"simple": false,
"required": false,
"writable": true,
"collectionName": "organisationUnits",
"min": 0,
"nameableObject": true,
"klass": "java.util.Set",
"propertyType": "COLLECTION",
"oneToOne": false,
"attribute": false,
"href": "http://localhost:8080/dhis/api/schemas/organisationUnit",
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": true,
"max": 2147483647,
"cascade": "none",
"manyToMany": true,
"collection": true,
"owningRole": "org.hisp.dhis.user.User.organisationUnits",
"itemPropertyType": "REFERENCE",
"collectionWrapping": true,
"itemKlass": "org.hisp.dhis.organisationunit.OrganisationUnit",
"inverseRole": "org.hisp.dhis.organisationunit.OrganisationUnit.users",
"apiEndpoint": "http://localhost:8080/dhis/api/organisationUnits",
"unique": false,
"name": "organisationUnit",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "href",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "URL",
"oneToOne": false,
"attribute": true,
"owner": false,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"manyToMany": false,
"collection": false,
"unique": false,
"name": "href",
"persisted": false,
"manyToOne": false,
"constants": []
},
{
"fieldName": "introduction",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"cascade": "none",
"manyToMany": false,
"length": 2147483647,
"collection": false,
"unique": false,
"name": "introduction",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "email",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 160,
"cascade": "none",
"manyToMany": false,
"length": 160,
"collection": false,
"unique": false,
"name": "email",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"relativeApiEndpoint": "/organisationUnits",
"fieldName": "dataViewOrganisationUnits",
"simple": false,
"required": false,
"writable": true,
"collectionName": "dataViewOrganisationUnits",
"min": 0,
"nameableObject": true,
"klass": "java.util.Set",
"propertyType": "COLLECTION",
"oneToOne": false,
"attribute": false,
"href": "http://localhost:8080/dhis/api/schemas/organisationUnit",
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": true,
"max": 2147483647,
"cascade": "none",
"manyToMany": true,
"collection": true,
"owningRole": "org.hisp.dhis.user.User.dataViewOrganisationUnits",
"itemPropertyType": "REFERENCE",
"collectionWrapping": true,
"itemKlass": "org.hisp.dhis.organisationunit.OrganisationUnit",
"apiEndpoint": "http://localhost:8080/dhis/api/organisationUnits",
"unique": false,
"name": "dataViewOrganisationUnit",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "userGroupAccesses",
"simple": false,
"required": false,
"writable": true,
"collectionName": "userGroupAccesses",
"min": 0,
"nameableObject": false,
"klass": "java.util.Set",
"propertyType": "COLLECTION",
"oneToOne": false,
"attribute": false,
"owner": false,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"manyToMany": false,
"collection": true,
"itemPropertyType": "COMPLEX",
"collectionWrapping": true,
"itemKlass": "org.hisp.dhis.user.UserGroupAccess",
"unique": false,
"name": "userGroupAccess",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": false,
"manyToOne": false,
"constants": []
},
{
"fieldName": "languages",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"cascade": "none",
"manyToMany": false,
"length": 2147483647,
"collection": false,
"unique": false,
"name": "languages",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "created",
"description": "The date this object was created.",
"simple": true,
"required": false,
"writable": true,
"nameableObject": false,
"klass": "java.util.Date",
"propertyType": "DATE",
"oneToOne": false,
"attribute": true,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"cascade": "none",
"manyToMany": false,
"length": 255,
"collection": false,
"unique": false,
"name": "created",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "userCredentials",
"simple": false,
"required": false,
"writable": true,
"nameableObject": false,
"klass": "org.hisp.dhis.user.UserCredentials",
"propertyType": "REFERENCE",
"oneToOne": true,
"attribute": false,
"href": "http://localhost:8080/dhis/api/schemas/userCredentials",
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": true,
"cascade": "none",
"manyToMany": false,
"collection": false,
"unique": false,
"name": "userCredentials",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "attributeValues",
"simple": false,
"required": false,
"writable": true,
"collectionName": "attributeValues",
"min": 0,
"nameableObject": false,
"klass": "java.util.Set",
"propertyType": "COLLECTION",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"cascade": "delete-orphan",
"manyToMany": true,
"collection": true,
"owningRole": "org.hisp.dhis.user.User.attributeValues",
"itemPropertyType": "COMPLEX",
"collectionWrapping": true,
"itemKlass": "org.hisp.dhis.attribute.AttributeValue",
"unique": false,
"name": "attributeValue",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "lastCheckedInterpretations",
"simple": true,
"required": false,
"writable": true,
"nameableObject": false,
"klass": "java.util.Date",
"propertyType": "DATE",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"cascade": "none",
"manyToMany": false,
"length": 255,
"collection": false,
"unique": false,
"name": "lastCheckedInterpretations",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"relativeApiEndpoint": "/userGroups",
"fieldName": "groups",
"simple": false,
"required": false,
"writable": true,
"collectionName": "userGroups",
"min": 0,
"nameableObject": false,
"klass": "java.util.Set",
"propertyType": "COLLECTION",
"oneToOne": false,
"attribute": false,
"href": "http://localhost:8080/dhis/api/schemas/userGroup",
"owner": false,
"readable": true,
"ordered": false,
"identifiableObject": true,
"max": 2147483647,
"cascade": "none",
"manyToMany": true,
"collection": true,
"owningRole": "org.hisp.dhis.user.UserGroup.members",
"itemPropertyType": "REFERENCE",
"collectionWrapping": true,
"itemKlass": "org.hisp.dhis.user.UserGroup",
"inverseRole": "org.hisp.dhis.user.User.groups",
"apiEndpoint": "http://localhost:8080/dhis/api/userGroups",
"unique": false,
"name": "userGroup",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "firstName",
"simple": true,
"required": true,
"writable": true,
"min": 2,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 160,
"cascade": "none",
"manyToMany": false,
"length": 160,
"collection": false,
"unique": false,
"name": "firstName",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "phoneNumber",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 80,
"cascade": "none",
"manyToMany": false,
"length": 80,
"collection": false,
"unique": false,
"name": "phoneNumber",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "nationality",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 160,
"cascade": "none",
"manyToMany": false,
"length": 160,
"collection": false,
"unique": false,
"name": "nationality",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"fieldName": "name",
"description": "The name of this Object. Required and unique.",
"simple": true,
"required": false,
"writable": true,
"min": 1,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": true,
"owner": false,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"manyToMany": false,
"collection": false,
"unique": false,
"name": "name",
"persisted": false,
"manyToOne": false,
"constants": []
},
{
"fieldName": "interests",
"simple": true,
"required": false,
"writable": true,
"min": 0,
"nameableObject": false,
"klass": "java.lang.String",
"propertyType": "TEXT",
"oneToOne": false,
"attribute": false,
"owner": true,
"readable": true,
"ordered": false,
"identifiableObject": false,
"max": 2147483647,
"cascade": "none",
"manyToMany": false,
"length": 2147483647,
"collection": false,
"unique": false,
"name": "interests",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": true,
"manyToOne": false,
"constants": []
},
{
"relativeApiEndpoint": "/users",
"fieldName": "user",
"simple": false,
"required": false,
"writable": true,
"nameableObject": false,
"klass": "org.hisp.dhis.user.User",
"propertyType": "REFERENCE",
"oneToOne": false,
"attribute": false,
"href": "http://localhost:8080/dhis/api/schemas/user",
"owner": false,
"readable": true,
"ordered": false,
"identifiableObject": true,
"manyToMany": false,
"collection": false,
"apiEndpoint": "http://localhost:8080/dhis/api/users",
"unique": false,
"name": "user",
"namespace": "http://dhis2.org/schema/dxf/2.0",
"persisted": false,
"manyToOne": false,
"constants": []
}
]
}