freshbooks-php-sdk

Client extends DataTransferObject implements DataModel

A client in the new FreshBooks is a resource representing an entity you send invoices to.

Tags
link
https://www.freshbooks.com/api/clients

Table of Contents

Interfaces

DataModel

Constants

RESPONSE_FIELD  = 'client'

Properties

$accountingSystemId  : string
$billingCity  : string
$billingCode  : string
$billingCountry  : string
$billingProvince  : string
$billingStreet  : string
$billingStreet2  : string
$businessPhone  : string
$companyIndustry  : string
$companySize  : string
$currencyCode  : string
$email  : string
$fax  : string
$firstName  : string
$homePhone  : string
$id  : int
$language  : string
$lastActivity  : string
$lastName  : string
$mobilePhone  : string
$note  : string
$organization  : string
$shippingCity  : string
$shippingCode  : string
$shippingCountry  : string
$shippingProvince  : string
$shippingStreet  : string
$shippingStreet2  : string
$signupDate  : DateTimeImmutable
$updated  : DateTimeImmutable
$userId  : int
$vatName  : string
$vatNumber  : string
$visState  : int

Methods

getContent()  : array<string|int, mixed>
Get the data as an array to POST or PUT to FreshBooks, removing any read-only fields.

Constants

RESPONSE_FIELD

public mixed RESPONSE_FIELD = 'client'

Properties

$accountingSystemId

public string $accountingSystemId

Unique identifier of account the client exists on.

Attributes
#[MapFrom]
'accounting_systemid'

$billingCity

public string $billingCity

Billing address city.

Attributes
#[MapFrom]
'p_city'
#[MapTo]
'p_city'

$billingCode

public string $billingCode

Billing address postal code.

Attributes
#[MapFrom]
'p_code'
#[MapTo]
'p_code'

$billingCountry

public string $billingCountry

Billing address country.

Attributes
#[MapFrom]
'p_country'
#[MapTo]
'p_country'

$billingProvince

public string $billingProvince

Short form of province/state for billing address.

Attributes
#[MapFrom]
'p_province'
#[MapTo]
'p_province'

$billingStreet

public string $billingStreet

Billing address street.

Attributes
#[MapFrom]
'p_street'
#[MapTo]
'p_street'

$billingStreet2

public string $billingStreet2

Billing address, additional street info.

Attributes
#[MapFrom]
'p_street2'
#[MapTo]
'p_street2'

$businessPhone

public string $businessPhone

Business phone number.

Attributes
#[MapFrom]
'bus_phone'
#[MapTo]
'bus_phone'

$companyIndustry

public string $companyIndustry

Description of industry client is in.

Attributes
#[MapFrom]
'company_industry'
#[MapTo]
'company_industry'

$companySize

public string $companySize

Size of client's company.

Attributes
#[MapFrom]
'company_size'
#[MapTo]
'company_size'

$currencyCode

public string $currencyCode

3-letter shortcode for client's preferred currency. Eg. USD, CAD, EUR

Attributes
#[MapFrom]
'currency_code'
#[MapTo]
'currency_code'

$email

public string $email

Client's email.

$fax

public string $fax

Client's fax number.

$firstName

public string $firstName

Client's first name.

Attributes
#[MapFrom]
'fname'
#[MapTo]
'fname'

$homePhone

public string $homePhone

Client's home phone number.

Attributes
#[MapFrom]
'home_phone'
#[MapTo]
'home_phone'

$id

public int $id

The unique identifier of this client within this business.

$language

public string $language

Shortcode indicating user language e.g. "en"

$lastActivity

public string $lastActivity

The last client activity action.

Note: This returns as "null" in all calls unless a "last_activity" include parameter is provided.

Attributes
#[MapFrom]
'last_activity'

$lastName

public string $lastName

Client's last name.

Attributes
#[MapFrom]
'lname'
#[MapTo]
'lname'

$mobilePhone

public string $mobilePhone

Client's mobile phone number.

Eg. "416-444-4444"

Attributes
#[MapFrom]
'mob_phone'
#[MapTo]
'mob_phone'

$note

public string $note

Notes kept by admin about client.

$organization

public string $organization

Name for client's business.

$shippingCity

public string $shippingCity

Shipping address city.

Attributes
#[MapFrom]
's_city'
#[MapTo]
's_city'

$shippingCode

public string $shippingCode

Shipping address postal code.

Attributes
#[MapFrom]
's_code'
#[MapTo]
's_code'

$shippingCountry

public string $shippingCountry

Shipping address country.

Attributes
#[MapFrom]
's_country'
#[MapTo]
's_country'

$shippingProvince

public string $shippingProvince

Short form of province/state for shipping address.

Attributes
#[MapFrom]
's_province'
#[MapTo]
's_province'

$shippingStreet

public string $shippingStreet

Shipping address street.

Attributes
#[MapFrom]
's_street'
#[MapTo]
's_street'

$shippingStreet2

public string $shippingStreet2

Shipping address, second street info.

Attributes
#[MapFrom]
's_street2'
#[MapTo]
's_street2'

$signupDate

public DateTimeImmutable $signupDate

The signup time of the client.

Attributes
#[CastWith]
\amcintosh\FreshBooks\Model\Caster\AccountingDateTimeImmutableCaster::class
$isUtc: true
#[MapFrom]
'signup_date'

$updated

public DateTimeImmutable $updated

The time of last modification.

Attributes
#[CastWith]
\amcintosh\FreshBooks\Model\Caster\AccountingDateTimeImmutableCaster::class

$userId

public int $userId

Duplicate of id

Attributes
#[MapFrom]
'userid'

$vatName

public string $vatName

The "Value Added Tax" name

Attributes
#[MapFrom]
'vat_name'
#[MapTo]
'vat_name'

$vatNumber

public string $vatNumber

The "Value Added Tax" number

Attributes
#[MapFrom]
'vat_number'
#[MapTo]
'vat_number'

Methods

getContent()

Get the data as an array to POST or PUT to FreshBooks, removing any read-only fields.

public getContent() : array<string|int, mixed>
Return values
array<string|int, mixed>

        
On this page

Search results