server
server copied to clipboard
[EPIC] Helper functions
Some button in the webinterface or calls in the API require a bit more logic to implement. Examples of those calls are:
- Import HC Mask
- Assign/unassign agent
Those calls are not simply the modification of a single attribute of an object. But require multiple steps maybe even interacting with multiple objects. Those calls are important and are common actions that multiple interface would probably need. To implement those items a helper api end point should be implemented.
- Endpoint:
/v2/helper
Post data:
{
data: {chunkId: 1 }
}
Return data, PSR7 status message or JSON API response
{
status: 200,
status_details: 'chunk aborted',
data: {chunkId: 1}
}
Example calls:
- SetSuperTaskTopPrio
- UnAssignAgent
- AssignAgent
Naming scheme of calls:
[cmd][object][action][parameter]
doChunkAbort
doAgentUnassign
doHashlistAddPlain
There is the AbstractBaseAPI model, with the ModelBaseAPI. Helper should also be a child of the AbstractBaseAPI
Todo:
- [ ] Import HC mask
- [x] Reset Password
- [ ] #686