Giter Site home page Giter Site logo

bexio-api-client's People

Contributors

cbaconnier avatar christianruhstaller avatar onlime avatar tomasz-silpion avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

buepro araeubig

bexio-api-client's Issues

Trying to search in invoices but always my fields "are not set"

Sorry for disturbing with perhaps a very silly question, but i can't see actually my error:

I try to search for invoices with this code:

<?php

require_once '../vendor/autoload.php';
require_once 'bexio-api.php';

use Bexio\Client;
use Bexio\Resource\Invoice;

$client = new Client($clientId, $clientSecret);
$client->loadTokens($tokensFile);

$bexioInvoice = new Invoice($client);

//$invoices = $bexioInvoice->getInvoices();


$params = array(
    "field" => "kb_item_status_id",
    "value" => "8",
    "criteria" => "="
);

$invoices = $bexioInvoice->searchInvoices($params);

echo "<pre>";
print_r($invoices);
echo "</pre>";

But i always get this error:

Fatal error: Uncaught Bexio\Exception\BexioClientException: The following search parameters could not have been applied: ["field not set","field not set","field not set"] in /workspaces/bexio-stripe-pos-backend/www/vendor/onlime/bexio-api-client/src/Bexio/Client.php on line 63 Bexio\Exception\BexioClientException: The following search parameters could not have been applied: ["field not set","field not set","field not set"] in /workspaces/bexio-stripe-pos-backend/www/vendor/onlime/bexio-api-client/src/Bexio/Client.php on line 63 Call Stack: 0.0003 474576 1. {main}() /workspaces/bexio-stripe-pos-backend/www/bexio-v2/invoices.php:0 0.0011 575328 2. Bexio\Resource\Invoice->searchInvoices($params = ['field' => 'kb_item_status_id', 'value' => '8', 'criteria' => '='], $queryParams = ???) /workspaces/bexio-stripe-pos-backend/www/bexio-v2/invoices.php:23 0.0011 575328 3. Bexio\Client->post($path = 'kb_invoice/search', $data = ['field' => 'kb_item_status_id', 'value' => '8', 'criteria' => '='], $queryParams = []) /workspaces/bexio-stripe-pos-backend/www/vendor/onlime/bexio-api-client/src/Bexio/Resource/Invoice.php:22 0.0011 575328 4. Bexio\Client->request($path = 'kb_invoice/search', $method = 'POST', $data = ['field' => 'kb_item_status_id', 'value' => '8', 'criteria' => '='], $queryParams = []) /workspaces/bexio-stripe-pos-backend/www/vendor/onlime/bexio-api-client/src/Bexio/Client.php:18

It would be great to get a small hint - Thank you very much.

Regards André

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.