Suppose there is POST /inteview/:id/invite route.
Parameters are email addresses:
{ 'emails': ['[email protected]', '[email protected]'] }
Response should indicate that some addresses are successfully invited some not. For example:
[ {
"email": "[email protected]",
"status": "already invited"
},
{
"email": "[email protected]",
"status": "already invited"
}
]
Which status to return for partial success?
The Response's HTTP Status Code should be
200 OK, since you are getting the expected server's response.Whether an email is invited or not, is not an actual error.