Required Fields and relationships
Depending on the question you are attempting to answer, you will need to use the correct attribute. You will also need to provide the answerable
relationship with your request - this can be either an application
or job_seeker
record
Question type | Required attributes | Required Relationships |
---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| None |
|
|
|
|
|
|
|
Examples of how to submit different answer types
{
"data": {
"type": "answers",
"attributes": {
"text_answer": "Hello, Globe!"
},
"relationships": {
"answerable": {
"data": {
"type": "applications",
"id": "1"
}
},
"question": {
"data": {
"type": "questions",
"id": "1"
}
}
}
}
}
{
"data": {
"type": "answers",
"attributes": {
"boolean_answer": true
},
"relationships": {
"answerable": {
"data": {
"type": "applications",
"id": "1"
}
},
"question": {
"data": {
"type": "questions",
"id": "1"
}
}
}
}
}
{
"data": {
"type": "answers",
"attributes": {
"number_answer": 123
},
"relationships": {
"answerable": {
"data": {
"type": "applications",
"id": "1"
}
},
"question": {
"data": {
"type": "questions",
"id": "1"
}
}
}
}
}
{
"data": {
"type": "answers",
"attributes": {
"url_answer": "https://pinpointhq.com"
},
"relationships": {
"answerable": {
"data": {
"type": "applications",
"id": "1"
}
},
"question": {
"data": {
"type": "questions",
"id": "1"
}
}
}
}
}
{
"data": {
"type": "answers",
"attributes": {
"document_base64_filename": "example.pdf",
"document_base64_data": "data:application/pdf;base64,...[REDACTED_DATA]..."
},
"relationships": {
"answerable": {
"data": {
"type": "applications",
"id": "1"
}
},
"question": {
"data": {
"type": "questions",
"id": "1"
}
}
}
}
}
{
"data": {
"type": "answers",
"relationships": {
"answerable": {
"data": {
"type": "applications",
"id": "4"
}
},
"question": {
"data": {
"type": "questions",
"id": "22"
}
},
"answer_options": {
"data": [
{
"type": "answer_options",
"method": "create",
"temp-id": "temp-1"
},
{
"type": "answer_options",
"method": "create",
"temp-id": "temp-2"
}
]
}
}
},
"included": [
{
"type": "answer_options",
"temp-id": "temp-1",
"attributes": {
"text": "React"
}
},
{
"type": "answer_options",
"temp-id": "temp-1",
"attributes": {
"text": "Vue"
}
}
]
}
Example Description
{
"data": {
"type": "answers",
"attributes": {
"date_answer": "2020-01-01"
},
"relationships": {
"answerable": {
"data": {
"type": "applications",
"id": "1"
}
},
"question": {
"data": {
"type": "questions",
"id": "1"
}
}
}
}
}
{
"data": {
"type": "answers",
"attributes": {
"date_from_answer": "2022-01-01",
"date_to_answer": "2024-04-03"
},
"relationships": {
"answerable": {
"data": {
"type": "applications",
"id": "1"
}
},
"question": {
"data": {
"type": "questions",
"id": "1"
}
}
}
}
}