Get issues by date not working
Issue #58
resolved
Hey there, is there a way to get issues by date?
I tried the following code, but it gives me a
Uncaught Buzz\Exception\RequestException: Operation timed out after 10000 milliseconds with 0 bytes received in /home/constantin/PhpstormProjects/bb-reports/vendor/kriswallsmith/buzz/lib/Buzz/Client/Curl.php:29
Code sample:
$issues = $this->issue->all($_ENV['BB_ACCOUNT'], $_ENV['BB_REPO'],
array( 'state' => 'open', 'created_on' => ">= 2017-03-15T10:49:10+0000")
);
Do I have to specify an extra parameter?
Comments (3)
-
-
reporter Thanks for the help! I will try that.
-
reporter - changed status to resolved
Works as described.
- Log in to comment
The problem is that
Issues:all
is still using v1 of the Bitbucket Api and filtering by creation date is available only in v2 of the Api.The solution is to manually tell the library to use v2 of the Bitbucket Api.
As a side note, be careful with the date format. The Api server is expecting the date to be ISO 8601, so instead of
2017-03-15T10:49:10+0000
it should be2017-03-15T10:49:10+00:00
.