Skip to main content

Request Refill URL

POST/api/v1/cases/:caseId

Generates a refill URL for a case using the REQUEST_REFILL_URL action.

cv-api-key
Productionhttps://api.care360-next.carevalidate.com/api/v1/cases/:caseId
Staginghttps://api-staging.care360-next.carevalidate.com/api/v1/cases/:caseId

Parameters

Path Parameters
caseIdstringrequired

The unique identifier (UUID) of the case.

Headers
cv-api-keystringrequired

Your unique API key for authentication.

Content-Typestringrequired

Must be application/json.

Example: application/json
Request Body
actionstringrequired

Action to perform. Must be `REQUEST_REFILL_URL`.

Values:REQUEST_REFILL_URL
organizationProductIdstringoptional

Optional product identifier (UUID).

Validation Rules

  • organizationProductId: If provided, must be a valid UUID (Product id must be a valid UUID).

Examples

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"
}'

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