Giter Site home page Giter Site logo

fogbugz-php-api's People

Contributors

chadhutchins avatar craig-davis avatar learningstation avatar lordspace avatar mrrio avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fogbugz-php-api's Issues

logoff() function

Hi all

There is a function named logoff() in Api.php. This function send logoff command and clear our $token var.

But the problem is that you don't use this function in your sample.php.

Thanks.

Add set_token method and don't do logon

Hi,

Nice & well organized code.
I wasn't feeling ok saving my user/email + pwd in the files.
So I created the following method and supply it with the token that I generated from the FogBugz control panel.

    public function set_token($token) {
        $this->token = (string) $token;
    }

Update search to paginate and handle new `max` parameter

From FogBugz:

We have an update coming soon to the FogBugz XML API which changes a default behavior. We have not designated this as a breaking change because we designed it not to impact any accounts with normal usage. (i.e. the major version and minversion reported by api.xml will not change) It is important, however, for makers of applications and libraries to verify that case searches and filters are not requesting too many cases back from FogBugz.

Currently, if you do not specify a 'max' parameter when you use the 'search' or 'listCases' commands, FogBugz returns all matching results. In practice, we find that requests often time out for more than around 10,000 cases so there is a de facto limit which depends on the query. When we roll this change out to FogBugz On Demand accounts, the default behavior when no 'max' parameter is given or max is set to 0 will be to limit the results to 50,000 cases. In our testing, asking for more than 100,000 cases causes undue load on our servers and can negatively impact other accounts, so we now return an error (code 30) for anything more than 'max=100000'.

Please take a look at your code and, if possible, ensure that it is setting a value for the 'max' parameter. If the user is able to set a max, make sure your code passes the error code 30 along to them if they ask for more than 100,000 results.

Issue with the listIntervals method in fogbugz API

So I have been using the fogbugz API to call methods to retrieve data and everything works fine , except that there's something that I do not understand, When I see what is contained in the XML file, I have this time of format for listintervals for a particular user , the ixinterval tag contains a very big number like the first one has 5430 and I was expecting it to be hours , like 2 or 2.5, etc .. Can someone explain what that interval number means because on the fogbugz API documentation , the numbers are much smaller and represent hours and I'm pretty sure I didn't work that many hours on these projects. .. I'd really appreciate your help in this.

<interval>
<ixInterval>5430</ixInterval>
<ixPerson>96</ixPerson>
<ixBug>12250</ixBug>
<dtStart>2014-12-31T18:00:00Z</dtStart>
<dtEnd>2014-12-31T23:00:00Z</dtEnd>
<fDeleted>false</fDeleted>
<sTitle>
<![CDATA[
 err page when login to facebook account from upload photo
]]>
</sTitle>
</interval>
<interval>
<ixInterval>5462</ixInterval>
<ixPerson>96</ixPerson>
<ixBug>12479</ixBug>
<dtStart>2015-01-02T18:00:00Z</dtStart>
<dtEnd>2015-01-02T21:14:00Z</dtEnd>
<fDeleted>false</fDeleted>
<sTitle>
<![CDATA[
 Cannot See the Front of an Easel in My Orders
]]>
</sTitle>
</interval>

Curl Through Proxy Server

Hi,
I've started using your code through Packagist in a Symfony project. My Internal work network unfortunately uses a very aggressive proxy server set-up, which means I need to be able to pass proxy credentials though with each of the curl requests. Obviously modifying your downloaded code in the vendor folder of the Symfony project isn't ideal.

As I see it there are 2 possible solutions to the situation, currently the way you reference the 'curl' object in the main Fogbugz/Api class is via a public object, this allows me to overload it with my own implementation. Ideally I don't want to completely copy the code in case you put improvements in there, so the logical solution with that is to extend your 'Curl' class with my own, that implements a constructor which sets the proxy details via the curl_setopt function calls, however currently your $_ch parameter is set to 'private' rather than 'protected', which means that won't work.

The other solution would be for you to allow the option to set proxy data into the curl class itself via function calls (or optional construct parameters?).

Currently the code to set the proxy for my implementation is:

curl_setopt($this->_ch, CURLOPT_PROXY, "{$proxy_ip_address}:{$proxy_port}");
curl_setopt($this->_ch, CURLOPT_PROXYUSERPWD, "{$username}:{$password}");

Could this be implemented, or would you like me to do a pull request, implement the changes myself and then re-integrate that back into the core release? If so, which solution do you prefer?

Thanks,
John

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.