Jump to content

KingPin

Members
  • Posts

    32
  • Joined

  • Last visited

Posts posted by KingPin

  1. Thank you for the quick reply. I am currently quickly putting this together in bash and the following curl code works on company 1 but not company 2 : 

    company1

    curl -v http://site.com/api/clients/create.json -u user:key \
    -d 'vars[client_group_id]=1' \
    -d 'vars[status]=active' \
    -d 'vars[company_id]=1' \
    -d 'vars[first_name]=first' \
    -d 'vars[last_name]=last' \
    -d 'vars[company]=company' \
    -d 'vars[username]=112233441' \
    -d 'vars[new_password]=somepass1324' \
    -d 'vars[confirm_password]=somepass1324' \
    -d 'vars[email]=imports@site.com' \
    -d 'vars[numbers][0][number]=+16465551234' \
    -d 'vars[numbers][1][number]=+17185554321' \
    -d 'vars[address1]=123 Front Street' \
    -d 'vars[address2]=' \
    -d 'vars[city]=Brooklyn' \
    -d 'vars[state]=NY' \
    -d 'vars[zip]=10000' \
    -d 'vars[country]=US' \
    -d 'vars[settings][username_type]=username' \
    -d 'vars[settings][send_registration_email]=false' \
    -d 'vars[custom][1]=12345' \
    -d 'vars[custom][2]=12345
    
    

    company 2

    curl -v http://site.com/api/clients/create.json -u user:key \
    -d 'vars[client_group_id]=2' \
    -d 'vars[status]=active' \
    -d 'vars[company_id]=2' \
    -d 'vars[first_name]=first' \
    -d 'vars[last_name]=last' \
    -d 'vars[company]=company' \
    -d 'vars[username]=112233442' \
    -d 'vars[new_password]=somepass1324' \
    -d 'vars[confirm_password]=somepass1324' \
    -d 'vars[email]=imports@site.com' \
    -d 'vars[numbers][0][number]=+16465551234' \
    -d 'vars[numbers][1][number]=+17185554321' \
    -d 'vars[address1]=123 Front Street' \
    -d 'vars[address2]=' \
    -d 'vars[city]=Brooklyn' \
    -d 'vars[state]=NY' \
    -d 'vars[zip]=10000' \
    -d 'vars[country]=US' \
    -d 'vars[settings][username_type]=username' \
    -d 'vars[settings][send_registration_email]=false' \
    -d 'vars[custom][3]=12345' \
    -d 'vars[custom][4]=12345'
    
  2. I am creating multiple clients for 3 total companies under 1 blesta license with addon companies.
    I import from csv via curl calls and everything worked great for company #1. client ids went from 1500 - 1545.
    When I create a client for a 2nd company I dont get a full response back with all the client data of the newly created client. its like its adding contacts instead of clients. I get a simple :

    {"response":false}

     

    And all the clients are created with ID 1546. If I create a client via the gui it gets ID 1547 and is created fine. has anyone noticed anything similar to this before?

     

     thank you.

  3. Hi Tyson, thank you for your detailed response. Unfortunately I wasn't clear in my question, let me try to clarify.

    All my customers live in same state. but based on their residence county they get taxed differently. I have some customers who due to certain tax rules get charged 14% tax and others which get charged 10%. I need to be able to either set 2 tax rules and pick which one gets applied or have a field for a custom tax amount to be applied. Thank you.

  4. Was trying to add a service with invoice using cpanel module but with no actual provision as the service already exists on cpanel server.

    the term is 1 year. after adding the details I goto the next page which displays all the info and gives me two buttons, either to add service or edit service (URL admin/clients/addservice/4/3/1). when I click on add service I get the following error.

     

    Array to string conversion on line 18 in /billing/vendors/h2o/h2o/datatype.php

     

    when checking on client side the service is added to the client, but no invoice is created.

     

    Blesta version 3.0 released

    OS : cloud linux 6.0 x64

    php : 5.4.17

    Apache 2.2

    Mysql 5.5.32

     

     

    for quick ref. the line from error above is the return line in this function (in class StreamWriter) :

     

        function close() {
            $this->close = true;
            return implode('', $this->buffer);
        }

     

×
×
  • Create New...