---
title: "Register a new user"
method: POST
path: "/persons"
tags: ["Persons"]
---

# Register a new user

`POST /persons`

Add an Investor Person to the system and associate it to a Firm and  optionally to an Advisor. Registering a new Person does not require prior authentication. </br> <span>&#8226;</span> The Firm to which the  Person is to be added must have the "Investor self-signup " feature enabled.  </br> <span>&#8226;</span> The user is created as SSO,  non-SSO, or UIM JWT as determined by how the firm is configured for creating new "Clients ". </br></br>**Request Headers**</br>Registering a  new Person does not require prior authentication, so JSESSIONID or CSRF-TOKEN are not required. </br></br>A UIM Admin JWT can optionally be  submitted to this endpoint using the Authorization header with the header value "Bearer <token-value>".  The UIM Admin JWT holds a Service  Administrator level authentication context  and the UIM Guid for the user to be created must be provided in the post body. The endpoint will  validate the JWT, extract the UIM Guid, and store the UIM Guid on the Person. The UIM Guid must be unique across the ByAllAccounts system (across all Persons). If not, then the Person is not created and HTTP   409 Conflict is returned with the person URI.</br></br>The POST body  parameters listed in Model below are to be submitted in in JSON format as shown in the Example Value. </br></br>**Response Body**</br>Location  header:  URI to new resource. For example: </br> { "uri": "https://www.byallaccounts.net/api/v1/persons/12345s":     }</br>Where 12345 is the BAA Person Id for the new Person.

## Request body

- PersonPost — Profile data of a person to be added
  - `firstName` string, required — First name of the Person
  - `middleName` string — Middle name of the Person
  - `lastName` string, required — Last name of the Person
  - `role` string, required — Role of the Person. Currently must be the value ""
  - `emailAddress` string, required — Email address of the Person. Must be in the form of xx@yy.zzz
  - `phoneNumber` string — Phone number of the Person. There are no format requirements
  - `taxId` string — Social Security Number or Tax ID of the Person. Is only required if the Firm configuration requires a value for this field
  - `firmTag1` string — Firm tag 1. If specified, the value must be unique within the Firm to which the new Person is to be added. If not, HTTP 409 Conflict is returned. Is only required if the Firm configuration requires a value for this field
  - `firmTag2` string — Firm tag 2. Is only required if the Firm configuration requires a value for this field
  - `firmTag3` string — Firm tag 3. Is only required if the Firm configuration requires a value for this field
  - `firmCode` string — Vendor name value for the Firm to which this Investor should be added. The Firm must already exist. At least one of firmCode or advisorId must be specified in order identify to which firm to add the Person. If firmCode is specified and advisorId is not, then the Person is created without any association to an advisor. If both are specified, then they must not conflict, meaning the Advisor identified by advisorId must exist within the Firm identified by the firmCode. Otherwise, an HTTP 400 Bad Request is returned
  - `advisorId` integer — ByAllAccounts Person Id for the Advisor to whom this Investor should be assigned after the Investor is created. The Advisor must already exist and be part of the Firm identified in firmCode (if firmCode is specified). At least one of firmCode or advisorId must be specified in order identify to which firm to add the Person. If firmCode is specified and advisorId is not, then the Person is created without any association to an advisor. If both are specified, then they must not conflict, meaning the Advisor identified by advisorId must exist within the Firm identified by the firmCode. Otherwise, an HTTP 400 Bad Request is returned.
  - `uimGuid` string — Used in conjunction with Service Admin JWT. The uimGuid for the user to be created. Must be unique across all Persons in the ByAllAccounts system. If not, HTTP 409 Conflict is returned with the person URI. Ignored if a valid Service Admin JWT is not provided. Required when a Service Admin JWT is submitted to the endpoint.

## Response `200`

OK

- DataRecord
  - `data` object

## Other responses

- `201` — Created
- `400` — Bad Request. </br>Possible causes:</br> <span>&#8226;</span> The *field name* field is missing </br> <span>&#8226;</span> Missing required value </br> <span>&#8226;</span> The *field name* cannot exceed *max value* </br> <span>&#8226;</span> Invalid Role value </br> <span>&#8226;</span> Email addresses must be in the form x@x.x and cannot contain spaces </br> <span>&#8226;</span> Firm *firm* not found </br> <span>&#8226;</span> Advisor not found </br> </br>One of these is set on the Firm to be required but is not found:</br> <span>&#8226;</span> taxId </br> <span>&#8226;</span> firmTag1 </br> <span>&#8226;</span> firmTag2 </br> <span>&#8226;</span> firmTag3
- `401` — Not Authorized. </br>Possible causes:</br> <span>&#8226;</span> Investor self-signup not allowed </br><span>&#8226;</span> UIM JWT not valid
- `409` — Conflict. </br>Possible causes:</br><span>&#8226;</span> UIM Guid must be unique (from UIM JWT) </br><span>&#8226;</span> firmTag1 must be unique
- `500` — Internal Server Error

---

[API](https://skmtc.net/morningstar/apis/byallaccounts-api-07302024.md) · [All operations](https://skmtc.net/morningstar/apis/byallaccounts-api-07302024/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/morningstar/byallaccounts-api-07302024/revisions/8158207af2d9/schema)
