PHP code example of benancetin / youtrack-curly
1. Go to this page and download the library: Download benancetin/youtrack-curly library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
benancetin / youtrack-curly example snippets
bash
ncetin\Curly\Curly;
$curly = new benancetin\Curly\Curly();
$data = array(
"project" => array("id" =>"0-0"),
"summary" => "With curly everything is easy!",
"description" => "Let'\''s create a new issue using Curly."
);
$link = "/api/issues";
// you may use $curly-setJson($json) if you are sending json instead of array
$curly->setArray($data);
$response = $curly->execute("post",$link);
echo $response."<br/>";
// or you may get status codes and warnings by $curly->getWarnings();
$curly->printWarnings();