Create a new person
POST
/api/v1/person
const url = 'https://app.prefactorai.com/api/v1/person';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"email":"example","id":"013xrzp12g3nqk8ns6jadrqmpgrjkeny","name":"example","team_ids":["013xrzp12g3nqk8ns6jadrqmpgrjkeny"],"title":null}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://app.prefactorai.com/api/v1/person \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "email": "example", "id": "013xrzp12g3nqk8ns6jadrqmpgrjkeny", "name": "example", "team_ids": [ "013xrzp12g3nqk8ns6jadrqmpgrjkeny" ], "title": null }'Authorizations
Section titled “Authorizations”Request Body
Section titled “Request Body”Responses
Section titled “Responses”Success
Media typeapplication/json
object
details
required
Person_Details
object
email
required
Person email address
string
id
required
Person_Id
A valid person ID
string
inserted_at
required
When the person was created
string format: date-time
name
required
Person name
string
team_ids
required
Team IDs this person belongs to
Array<string>
type
required
Type of resource (always ‘person’)
string
updated_at
required
When the person was last updated
string format: date-time
status
required
string
Example
{ "details": { "email": "jane@example.com", "id": "013xrzp12g3nqk8ns6jadrqmpgrjkeny", "name": "Jane Doe", "team_ids": [ "013xrzp12g3nqk8ns6jadrqmpgrjkeny" ], "title": "Engineer", "type": "person" }, "status": "success"}default
Section titled “default”Error
Media typeapplication/json
One of:
object
code
required
string
message
required
string
status
required
string
object
code
required
string
errors
required
object
key
additional properties
object recursive
message
required
string
status
required
string
object
code
required
string
message
required
string
retry_after_ms
required
Milliseconds until the client may retry.
integer
status
required
string
Example
{ "code": "bad_request", "status": "error"}