Skip to content

List All Customers

Request

Lists all customers, including nested contacts for billing and delivery.

It also possible to change the sort order of the results of your query. You can sort by any of the following fields, in either ascending or descending order. Here are the examples:

https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=created_at&sort_dir=desc https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=created_at&sort_dir=asc https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=updated_at&sort_dir=desc https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=updated_at&sort_dir=asc https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=id&sort_dir=desc https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=id&sort_dir=asc https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=name&sort_dir=asc https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=name&sort_dir=desc https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=third_party_id&sort_dir=asc https://go.vworkapp.com/api/v5/customers.xml?api_key={{apikey}}&sort_by=third_party_id&sort_dir=desc

Security
apiKey
Query
api_keystringrequired
Headers
Accept-Encodingstringrequired

Must be gzip. The vWork API requires HTTP compression on all requests; requests without it may be rejected with 406 Not Acceptable (see Tech Notes → HTTP Compression).

Value:"gzip"
Example:gzip
GET
/v5/customers.xml
curl -i -X GET \
  'https://api.vworkapp.com/v5/customers.xml?api_key=string&api_key=YOUR_API_KEY_HERE' \
  -H 'Accept-Encoding: gzip'

Responses

OK

Headers
Cache-Controlstring
Example:"max-age=0, private, must-revalidate"
Content-Security-Policystring
Example:"frame-ancestors *.vworkapp.com *.vwork.io *.visfleet.com *.salesforce.com *.zoho.com, default-src: google.com google-analytics.com googleapis.com gst
Datestring
Example:"Mon, 13 Jun 2016 22:51:25 GMT"
ETagstring
Example:"W/\"4af298ed89390aecf7df64e20427d6ad\""
Statusstring
Example:"200 OK"
Strict-Transport-Securitystring
Example:"max-age=31536000"
Transfer-Encodingstring
Example:"chunked"
X-Content-Type-Optionsstring
Example:"nosniff"
X-Frame-Optionsstring
Example:"SAMEORIGIN"
X-Request-Idstring
Example:"52b7672b-d4fe-4ec8-88d7-e1bf8271e139"
X-Runtimestring
Example:"0.265632"
X-Unique-IDstring
Example:"CA7C7B8A:CBEF_0A001312:01BB_575F38C6_719C90:1E66"
X-XSS-Protectionstring
Example:"1; mode=block"
Bodyapplication/xml; charset=utf-8
string

Raw XML payload — see the example.

Response
<?xml version="1.0" encoding="utf-8"?>
<customers type="array" current_page="1" per_page="1" total_pages="1" total_entries="1">
    <customer>
        <id>1119086</id>
        <name>Joe's Plumbing</name>
        <notes/>
        <third_party_id>ABC123</third_party_id>
        <billing_contact>
            <first_name>Bob</first_name>
            <last_name>Lei</last_name>
            <phone>1 555 111 1111</phone>
            <mobile/>
            <email/>
            <location>
                <id type="integer">23839050</id>
                <created_at type="datetime" readonly="readonly">2016-06-13T22:51:25+00:00</created_at>
                <updated_at type="datetime" readonly="readonly">2016-06-13T22:51:25+00:00</updated_at>
                <address1/>
                <address2/>
                <suburb/>
                <city/>
                <post_code/>
                <country/>
                <province/>
                <region/>
                <state/>
                <form…