Patient Add Form to Case
POST
/api/v1/customer-dynamic-case-formSubmits an intake form with question responses to an existing case.
cv-api-key
Production
https://api.care360-next.carevalidate.com/api/v1/customer-dynamic-case-formStaging
https://api-staging.care360-next.carevalidate.com/api/v1/customer-dynamic-case-formParameters
Headers
cv-api-keystringrequiredSecret API key for authentication
Request Body (JSON)
keystringoptionalAPI key (if not provided in header)
caseIdstringrequiredThe ID of the case to update
formTitlestringrequiredTitle of the form
formDescriptionstringoptionalDescription of the form
questionsarrayrequiredArray of question objects (see below)
Question Object
questionIdstringrequiredThe ID of the question
questionstringrequiredThe question text
typestringrequiredThe type of the question (e.g., text, file, multiselect)
requiredbooleanoptionalWhether the question is required
answeranyrequiredThe answer to the question
phibooleanoptionalWhether the question contains PHI
hintstringoptionalHint text for the question
placeholderstringoptionalPlaceholder text for the question
optionsarrayoptionalOptions for select/multiselect questions
Notes
- The
cv-api-keycan be provided either as a header or in thekeyfield of the request body. - The
questionsarray must contain at least one question object. - The response includes the
caseIdand the generatedformResponseIdfor the submission.
Examples
- cURL
curl -X POST "<BASE_URL>/api/v1/customer-dynamic-case-form" \
-H "cv-api-key: your-secret-key" \
-H "Content-Type: application/json" \
-d '{
"caseId": "abc123",
"formTitle": "Health Survey",
"formDescription": "Initial intake",
"questions": [
{ "questionId": "q1", "answer": "Yes" },
{ "questionId": "q2", "answer": 42 }
]
}'
Responses
▶200SuccessForm submitted successfully.
{
"status": 200,
"success": true,
"data": {
"caseId": "string",
"formResponseId": "string"
}
}
▶400Missing Required ParameterReturned when a required parameter (key, caseId, formTitle, or questions) is missing.
{
"status": 400,
"success": false,
"error": "The '<param>' param is required"
}
▶400Missing Question FieldReturned when a required field in a question is missing.
{
"status": 400,
"success": false,
"error": "The 'questions[<index>].<field>' field is required"
}
▶400Secret Key Not ProvidedReturned when the secret key is not provided.
{
"status": 400,
"success": false,
"error": "Secret key not provided!"
}
▶400Organization DisabledReturned when the partner organization is disabled.
{
"status": 400,
"success": false,
"error": "Partner organization is disabled"
}
▶400Invalid CaseReturned when the provided case is not valid for the organization.
{
"status": 400,
"success": false,
"error": "Provided case is not valid"
}
▶400Submission FailedReturned when the form cannot be submitted (no question responses).
{
"status": 400,
"success": false,
"error": "Case Form can't be Submitted."
}
Try It Out
Try itAPI Playground
▶