Get Customer Businesses
curl --request GET \
--url https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}import requests
url = "https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"status": "success",
"message": "Businesses associated with customer fetched successfully",
"data": {
"records": [
{
"id": "1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d",
"name": null,
"tin": null,
"address_line_1": null,
"address_line_2": null,
"address_city": null,
"address_state": null,
"address_postal_code": null,
"address_country": null,
"created_at": "2023-12-22T11:03:04.416Z",
"created_by": "1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d",
"updated_at": "2024-02-02T18:50:11.022Z",
"updated_by": "1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d",
"mobile": null,
"official_website": null,
"public_website": null,
"social_account": null,
"status": "INACTIVE",
"customer_id": "1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d",
"external_id": "87654321"
}
],
"total_pages": 1,
"total_items": 1
}
}Business
Get Customer Businesses
Get all businesses associated with a particular customerID.
GET
/
businesses
/
customers
/
{customerID}
Get Customer Businesses
curl --request GET \
--url https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}import requests
url = "https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.joinworth.com/case/api/v1/businesses/customers/{customerID}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"status": "success",
"message": "Businesses associated with customer fetched successfully",
"data": {
"records": [
{
"id": "1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d",
"name": null,
"tin": null,
"address_line_1": null,
"address_line_2": null,
"address_city": null,
"address_state": null,
"address_postal_code": null,
"address_country": null,
"created_at": "2023-12-22T11:03:04.416Z",
"created_by": "1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d",
"updated_at": "2024-02-02T18:50:11.022Z",
"updated_by": "1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d",
"mobile": null,
"official_website": null,
"public_website": null,
"social_account": null,
"status": "INACTIVE",
"customer_id": "1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d",
"external_id": "87654321"
}
],
"total_pages": 1,
"total_items": 1
}
}Path Parameters
Example:
"1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d"
Query Parameters
The unique external identifier provided during business creation. This can be a string or a UUID.
Examples:
"87654321"
"1a2b3c4d-5e6f-1a2b-3c4d-5e6f1a2b3c4d"
Was this page helpful?
⌘I