Correct Aphlict websocket URI construction after PHP8 compatibility changes
[phabricator.git] / src / applications / maniphest / conduit / ManiphestCreateTaskConduitAPIMethod.php
blobfac96372febfcd0610a8f074d4d7897cb1be0d4d
1 <?php
3 final class ManiphestCreateTaskConduitAPIMethod
4 extends ManiphestConduitAPIMethod {
6 public function getAPIMethodName() {
7 return 'maniphest.createtask';
10 public function getMethodDescription() {
11 return pht('Create a new Maniphest task.');
14 public function getMethodStatus() {
15 return self::METHOD_STATUS_FROZEN;
18 public function getMethodStatusDescription() {
19 return pht(
20 'This method is frozen and will eventually be deprecated. New code '.
21 'should use "maniphest.edit" instead.');
24 protected function defineParamTypes() {
25 return $this->getTaskFields($is_new = true);
28 protected function defineReturnType() {
29 return 'nonempty dict';
32 protected function defineErrorTypes() {
33 return array(
34 'ERR-INVALID-PARAMETER' => pht('Missing or malformed parameter.'),
38 protected function execute(ConduitAPIRequest $request) {
39 $task = ManiphestTask::initializeNewTask($request->getUser());
41 $task = $this->applyRequest($task, $request, $is_new = true);
43 return $this->buildTaskInfoDictionary($task);