get https://secure.fusebill.com/v1/customers/
This function is used to retrieve a customer object. Specify the unique Fusebill ID of the customer in your request.
Path Parameters
Property | Type | Description |
---|---|---|
customerId | integer | This is the id value which uniquely identifies a Customer record in the Fusebill system. This value is unique to each customer. |
Examples
curl -X GET "https://secure.fusebill.com/v1/customers/{customerId}" \
-H "Content-Type: application/json" \
-H "Authorization: Basic {APIKey}"
//query parameter
int queryParameter = {customerId};
//Setup API key
string apiKey = "{APIKey}";
//Configure URI
WebRequest request = WebRequest.Create("HTTPS://stg-secure.fusebill.com/v1/customers/"+queryParameter);
//Add Content type
request.ContentType = "application/json";
//Add Api key authorization
request.Headers.Add(HttpRequestHeader.Authorization, "Basic "+apiKey);
//Set request method
request.Method = "GET";
//Perform the request
var httpResponse = (HttpWebResponse)request.GetResponse();
//Record the response from our request
var result = "";
using (var streamReader = new StreamReader(httpResponse.GetResponseStream()))
{
result = streamReader.ReadToEnd();
}
#Import requests
import requests
#Pass in a dictionary to the Headers parameter
headers = {'Authorization' : 'Basic {APIKey}', 'Content-Type' : 'application/json'}
#Pass in your URI, Payload and Headers
r = requests.get('https://stg-secure.fusebill.com/v1/customers/183365', headers=headers)
print(r.content)
Response
{
"firstName": "Shields",
"middleName": "Payne",
"lastName": "Gillespie",
"companyName": "Cuizine",
"suffix": "Jr.",
"primaryEmail": "[email protected]",
"primaryPhone": 8784473067,
"secondaryEmail": "[email protected]",
"secondaryPhone": 8955793436,
"title": "Dr",
"reference": 100986,
"status": "Active",
"customerAccountStatus": "Good",
"currency": "USD",
"customerReference": {
"reference1": null,
"reference2": "customValue",
"reference3": null,
"salesTrackingCodes": [],
"id": 12000750,
"uri": "https://secure.fusebill.com/v1/customers/12000750"
},
"customerAcquisition": {
"adContent": null,
"campaign": null,
"keyword": null,
"landingPage": null,
"medium": null,
"source": null,
"id": 12000750,
"uri": "https://secure.fusebill.com/v1/customers/12000750"
},
"monthlyRecurringRevenue": 250,
"netMonthlyRecurringRevenue": 220,
"salesforceId": 12345678,
"salesforceAccountType": null,
"salesforceSynchStatus": "Enabled",
"netsuiteId": 12345678,
"netsuiteSynchStatus": "Enabled",
"netsuiteCustomerType": "Individual",
"portalUserName": "Shields1974",
"parentId": 12000749,
"quickBooksLatchType": null,
"quickBooksId": null,
"quickBooksSyncToken": null,
"hubSpotId": null,
"hubSpotCompanyId":null,
"geotabId": "7813",
"modifiedTimestamp": "2019-11-07T15:51:11.1915461Z",
"createdTimestamp": "2018-01-01T03:33:33.02",
"id": 12000750,
"uri": "https://secure.fusebill.com/v1/customers/12000750"
}
{
"ErrorId": 0,
"HttpStatusCode": 404,
"Errors": [
{
"Key": "Api Error",
"Value": "Customer with id 2 not found."
}
]
}