Request Refill URL
POST
/api/v1/cases/:caseIdGenerates a refill URL for a case using the REQUEST_REFILL_URL action.
cv-api-key
Production
https://api.care360-next.carevalidate.com/api/v1/cases/:caseIdStaging
https://api-staging.care360-next.carevalidate.com/api/v1/cases/:caseIdParameters
Path Parameters
caseIdstringrequiredThe unique identifier (UUID) of the case.
Headers
cv-api-keystringrequiredYour unique API key for authentication.
Content-TypestringrequiredMust be application/json.
Example:
application/jsonRequest Body
actionstringrequiredAction to perform. Must be `REQUEST_REFILL_URL`.
Values:REQUEST_REFILL_URL
organizationProductIdstringoptionalOptional product identifier (UUID).
Validation Rules
- organizationProductId: If provided, must be a valid UUID (
Product id must be a valid UUID).
Examples
- cURL
- JavaScript
- Python
curl --location '<BASE_URL>/api/v1/cases/:caseId' \
--header 'cv-api-key: <redacted>' \
--header 'Content-Type: application/json' \
--data-raw '{
"action": "REQUEST_REFILL_URL",
"organizationProductId": "e9a3e6a5-9538-4401-99bb-ead475547a36"
}'
const caseId = 'YOUR_CASE_ID';
const response = await fetch(
`https://api.care360-next.carevalidate.com/api/v1/cases/${caseId}`,
{
method: 'POST',
headers: {
'cv-api-key': 'YOUR_SECRET_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
action: 'REQUEST_REFILL_URL',
organizationProductId: 'e9a3e6a5-9538-4401-99bb-ead475547a36',
}),
}
);
const data = await response.json();
console.log(data);
import requests
case_id = "YOUR_CASE_ID"
url = f"https://api.care360-next.carevalidate.com/api/v1/cases/{case_id}"
headers = {
"cv-api-key": "YOUR_SECRET_KEY",
"Content-Type": "application/json",
}
payload = {
"action": "REQUEST_REFILL_URL",
"organizationProductId": "e9a3e6a5-9538-4401-99bb-ead475547a36",
}
response = requests.post(url, headers=headers, json=payload)
data = response.json()
print(data)
Responses
▶200SuccessRefill URL generated successfully.
{
"status": 200,
"success": true,
"formLink": "https://example.com/check-in-form-link"
}
▶400Invalid ActionReturned when the action field is not a recognized value.
{
"status": 400,
"success": false,
"message": "Invalid request",
"error": "Invalid action"
}
▶400Invalid Product IdReturned when organizationProductId is not a valid UUID.
{
"status": 400,
"success": false,
"message": "Invalid request",
"error": "Product id must be a valid UUID"
}
▶404Case Not FoundReturned when no case exists with the provided caseId.
{
"status": 404,
"success": false,
"message": "Invalid request",
"error": "No Case found for provided details!"
}
▶403Permission DeniedReturned when the case belongs to a different organization.
{
"status": 403,
"success": false,
"message": "Invalid request",
"error": "Permission denied!"
}
Try It Out
Try itAPI Playground
▶