Giter VIP home page Giter VIP logo

api-library-php5's People

Contributors

bernardosilva avatar brandesign avatar k3nn7 avatar peterjaap avatar skolodyazhnyy avatar valorin avatar vlmh avatar

Stargazers

 avatar  avatar  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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

api-library-php5's Issues

Curl Client does not check if response code is 200 or 201

I had an issue that I relied on your exceptions instead of the response of the CURL request. A response code of 400 couldn't be catched because there isn't an exception thrown if it occurs. An exception is only thrown when the result of the CURL request is false (https://github.com/onesky/api-library-php5/blob/master/src/Onesky/Api/Client.php#L360).
It is better to extend this check also with the CURL response code because only the expected response codes should be accepted.

Failed to authorize

I receive an error message "401 Fail to authorize":

$osaClient = new OneSkyApp\Client;
$osaClient->setApiKey(API_KEY));
$osaClient->setSecret(API_SECRET));
$osaClient->translations('export', array(
'project_id' => $projectId,
'locale' => $locale,
'source_file_name' => $filename
));

Deprecated curl stuff

Please update the Client to get rid of this warning:

Deprecated: curl_setopt(): The usage of the @filename API for file uploading is deprecated. Please use the CURLFile class instead in xxx/OneSky/Api.php on line 306

Thank you!

phrase-collections - 400 error - Project doesn't belong to phrase collection type

When iI try to

POST /projects/123/phrase-collections

I got this error:

[status] => 400
[message] => Project doesn't belong to phrase collection type

the params I am sending are similar to this:

array(1) {
  ["collections"]=>
  array(16) {
    ["campaign_label.en"]=>
    array(2) {
      ["updated"]=>
      array(1) {
        ["string"]=>
        string(7) "Updated"
      }
      ["new"]=>
      array(1) {
        ["string"]=>
        string(3) "New"
      }
    }
}

What does it mean?

Add code coverage badge to project.

Add project to: https://scrutinizer-ci.com/

Once you added this project need to do those changes:

On .travis.yml add this:

after_script:
    - wget https://scrutinizer-ci.com/ocular.phar
    - php ocular.phar code-coverage:upload --format=php-clover coverage.clover

Create new file: .scrutinizer.yml

imports:
    - php

tools:
    external_code_coverage:
        timeout: 1200    # Timeout in seconds.

Add code coverage badge to README.md

[![Code Coverage](https://scrutinizer-ci.com/g/onesky/api-library-php5/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/onesky/api-library-php5/?branch=master)

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.