Register Account
POST {url}/api/account
This API registers accounts in the PRIVO system. The attributes contained in the body of the request (in conjunction to proper scopes) determine what type of account is being created. Child accounts created with this API will be orphaned until such time that a Parent (e.g. Granter) gets involved in the registration flow. Use the /parent variable described below to access the most robust child registraions.
Depending on your Partner configuration either birthDate_YYYYMMDD or roleIdentifier is required to create
an account, but not both. If both are supplied, then they must match the defined role being accessed. If more than one
role exists that overlaps an age range then the roleIdentifier must be present.
NOTE: This API works best for Teen and Adult registrations.
Attributes defined in the body of the request must be set in Partner configurations in order for them to properly be used during API access. Missing attributes will be collected from the Granter during the permissioning process or from the User post-consent. See About Attributes section for more information about attribute use.
Child Registrations
When attempting to register a child with a parent associated then we suggest that you use the following API variation.
POST {url}/api/account/parent
This /parent API will register the child(ren) desired and automatically generate/associate the desired parent account. By using the /parent API, Partners can define specific attributes and features to assign to, not only, the child account but also to the Parent account. The JSON response will include the Parent serviceId.
API Endpoint:
/api/account
Parent API Endpoint:
/api/account/parent
Sample Adult Account Request with Birth Date:
POST {{url}}/api/account/
Body:
{
"firstName":"Sally",
"userName":"coolTeacher47",
"birthDate_YYYYMMDD":"19720605",
"email":"someEmailAddress@someDomain.com",
"gender":"Female"
}
Sample Adult Account Request with Role Identifier:
POST {{url}}/api/account/
Body:
{
"firstName":"Sally",
"userName":"coolTeacher47",
"roleIdentifier":"someAdultRole",
"email":"someEmailAddress@someDomain.com",
"gender":"Female"
}
Sample Adult JSON Response:
{
"validationErrors": [0],
"status": "success",
"message": null,
"resultCount": -1,
"totalCount": -1,
"entity": {
"serviceId": "5a334e59484......46673d3d",
"fullyRegistered": false,
"role": {}
"roleId": 101,
"roleIdentifier": "someAdultRole",
"shadowAccount": false,
"firstName": "Sally",
"lastName": null,
"middleInitial": null,
"email": "someEmailAddress@someDomain.com",
"emailVerified": false,
"birthDate": 76550400000,
"userName": "coolTeacher47",
"active": false,
"isMinor": false,
"isTeen": false,
"isTeacher": false,
"isStudent": false,
"gender": 2,
"genderType": "Female",
"registrationRole": "Adult",
"address": {
"streetAddress1": null,
"streetAddress2": null,
"city": null,
"stateProvince": null,
"postalCode": null,
"country": "US"
}
"creationDate": 1396282972776,
"activationDate": null,
"verificationTier": "A",
"id": "5a334e59484......46673d3d",
"fullName": "Sally",
"features": [],
"pin": "VYJJ30K",
"displayNames": [],
"modifiedDate": 1587751273264,
"consentUrl": "{url}/e/r/a?token=6c3254537931724b.....64413d3d",
"consentRequests": [],
"characteristics": [
"ADULT"
],
"connectedProfiles": [],
"hasPasscode": false,
"hasPassword": false
}
}
Sample Child Account Request with Parent:
POST {{url}}/api/account/parent
Body:
{
"email": "parentEmailAddress@someDomain.com",
"roleIdentifier": "someParentRoleIdentifier",
"minorRegistrations": [
{
"sendParentEmail": true,
"firstName": "Tammy",
"roleIdentifier": "someChildRoleIdentifier",
"gender": "2",
"birthDate_YYYYMMDD":"20100329",
"features":[
{"featureIdentifier": "someFeatureIdentifier"}
],
"attributes": [
{
"attributeName": "partnerPin",
"value": "someValue"
}
]
}
]
}
Sample Child/Parent JSON Response:
{
"validationErrors": [0],
"status": "success",
"message": null,
"resultCount": -1,
"totalCount": -1,
"entity": {
"serviceId": "5a334e59484......46673d3d",
"fullyRegistered": false,
"role": {}
"roleId": 101,
"roleIdentifier": "someParentRole",
"shadowAccount": false,
"firstName": null,
"lastName": null,
"middleInitial": null,
"email": "parentEmailAddress@someDomain.com",
"emailVerified": false,
"birthDate": 76550400000,
"userName": null,
"active": false,
"isMinor": false,
"isTeen": false,
"isTeacher": false,
"isStudent": false,
"gender": null,
"genderType": null,
"registrationRole": "Parent",
"address": {
"streetAddress1": null,
"streetAddress2": null,
"city": null,
"stateProvince": null,
"postalCode": null,
"country": "US"
}
"creationDate": 1396282972776,
"activationDate": null,
"verificationTier": "A",
"id": "5a334e59484......46673d3d",
"fullName": null,
"features": [],
"pin": "VYJJ30K",
"displayNames": [],
"modifiedDate": 1587751273264,
"consentUrl": "{url}/e/r/a?token=6c3254537931724b.....64413d3d",
"consentRequests": [
{
"status": "PENDING",
"pin": 1587753484188,
"consentDate": 1587753484188
}
],
"characteristics": [
"PARENT"
],
"connectedProfiles": [
{
"serviceId": "70424836326a4......16b413d3d",
"fullyRegistered": false,
"roleId": 12235,
"roleIdentifier": "someChildRoleIdentifier",
"shadowAccount": false,
"firstName": "Tammy",
"lastName": null,
"emailVerified": false,
"emailPending": false,
"birthDate": 1269820800000,
"isMinor": true,
"isTeen": false,
"isTeacher": false,
"isStudent": false,
"gender": "Female",
"address": {
"added": 1587753484215,
"modified": null,
"id": 38026172,
"version": 1,
"streetAddress1": null,
"streetAddress2": null,
"city": null,
"stateProvince": null,
"region": null,
"postalCode": null,
"country": "US",
"homePhoneNumber": null,
"faxNumber": null
},
"locale": "en_US",
"verificationTier": "A_",
"features": [],
"personId": 72888768,
"personSiteId": 75519658,
"attributes": [
{
"@class": "com.privo.ws.domain.account.Attribute",
"added": 1587753484322,
"modified": 1587753484322,
"id": 513541,
"version": 1,
"value": "JA50D3W",
"scope": "GLOBAL",
"personId": null,
"attributeDef": {
"@class": "com.privo.ws.domain.partner.AttributeDef",
"added": 1565028836000,
"modified": 1565034652000,
"id": 89326,
"version": 2,
"attribute": "partnerPin",
"attDefIdentifier": "partnerUserPin",
"label": "Partner PIN",
"rank": 10,
"regex": "",
"maxLength": 100,
"cssClass": "",
"systemAttribute": false,
"placeholderText": "Partner PIN",
"standardAttributeType": null,
"categoryType": "CUSTOM_ATTRIBUTE",
"widgetType": "TEXT",
"validationType": null,
"optionsType": null,
"optionsDef": null,
"partnerConfigId": 4907,
"options": [],
"readOnly": false,
"identifier": "partnerPin",
"attributeName": "partnerPin",
"standardAddressAttribute": false,
"referenceDef": null,
"personSiteAttribute": false,
"attributeEntityType": null,
"personAttribute": false,
"personAddressAttribute": false,
"attributeId": 894326,
"standardAttribute": false,
"_name": "attributeDef"
},
"attributeDefId": null,
"attributeName": null,
"attribute": {},
"attributeId": null
}
],
"siteId": {partnerSiteId},
"siteName": "Some Partner Site",
"siteToken": "4b766f4c565037......35158673d3d",
"displayNames": [],
"modifiedDate": 1587753484225,
"consentRequests": [
{
"status": "PENDING",
"pin": 1587753484295,
"consentDate": 1587753484295
}
],
"characteristics": [
"CHILD"
],
"connectedProfiles": [],
"fullName": "Tammy",
"minor": true,
"id": "70424836326a4......16b413d3d",
"registrationRole": "someChildRoleIdentifier",
"student": false,
"teen": false,
"teacher": false,
"hasPasscode": false,
"hasPassword": false,
"birthDate_yyyy": "2010"
}
],
"hasPasscode": false,
"hasPassword": false
}
}