Overview
Purpose
The REST API lets you interact with Interstate Billing Service from anything that can send an HTTP request. You can use the REST API to:
- Retrieve Customer information
- Retrieve Approval information
- Create Approvals
- Update Approvals
Quick Reference
All API access is over HTTPS, and accessed via the https://api.interstatebilling.net
domain with a relative path prefix of /api/
.
Customers
URL | HTTP Verb | Functionality |
---|---|---|
/api/customers/{ibsaccountid} | GET | Retrieving Customers by IBS Account ID |
/api/customers/name/{name} | GET | Retrieving Customers by Name |
/api/customers/status/{status} | GET | Retrieving Customers by Status |
Approvals
URL | HTTP Verb | Functionality |
---|---|---|
/api/approvals/{id} | GET | Retrieving Approvals by ID |
/api/approvals/invoicenumber/{invoicenumber} | GET | Retrieving Approvals by Invoice Number |
/api/approvals/approvalcode/{approvalcode} | GET | Retrieving Approvals by Approval Code |
/api/approvals/ | POST | Creating Approvals |
/api/approvals/{approvalcode} | PUT | Updating Approvals |
Request Format
For POST and PUT requests, the request body may be either JSON or XML, with the Content-Type header set to application/json or application/xml.
Basic Authentication is done via HTTP headers. The Authorization header identifies the API user's username and password (Base64 encoded) and the IBSLocationID header identifies the Company's location.
Customers
The Customers API allows you to retrieve your customer accounts by IBSAccountNumber, Name, or Status.
Customer Properties
Name | Description |
---|---|
IBSAccountNumber | The IBS Customer Account Number |
Name | The Customer Account Name |
Status | The Customer Account Status |
Retrieving Customers by IBS Account ID
GET /api/customers/{id}
To retrieve a customer by IBS Account Number, send a GET request to the customers URL. The response body is a JSON or XML Customer object.
Retrieving Customers by Name
GET /api/customers/name/{name}
To retrieve a list of customers by a %name% match, send a GET request to the customers/name URL with the name to match. The response body is a JSON or XML array of Customer objects.
Retrieving Customers by Status
GET /api/customers/status/{status}
To retrieve a list of customers of a specific status, send a GET request to the customers/status URL with the status to match. The response body is a JSON or XML array of Customer objects.
Approvals
The Approvals API allows you to create, update, and retrieve your approvals by ID, invoice number, or approval code.
Approval Properties - Common
Name | Description | Options |
---|---|---|
ID | Approval Unique ID | Generated by IBS system |
Amount* | Amount of Invoice | Limited to 11 digits with 2 decimals |
ApprovalCode | Approval Code if Approved | |
ApprovalType* | Type of Invoice | 'Parts','Service','Body Shop','Lease or Rental','Other' |
CalledInBy* | Name of person calling in approval | |
ContactName* | Name of person to contact if not approved | |
ContactBy* | Contact method | 'Email', 'Phone' |
ContactEmail* | Email address of person to contact | Required if ContactBy='Email' |
ContactPhone* | Phone number of person to contact | Required if ContactBy='Phone' |
FollowUpDate | Estimated date the invoice will be finalized and closed | |
IBSAccountNumber* | IBS Customer Account ID | |
IBSLocationID | IBS Dealer Location ID | |
InvoiceNumber | Invoice Number (11) | Limited to 11 chars |
PONumber | Purchase Order number | Limited to 12 chars |
Approval Properties - Parts
Name | Description | Options |
---|---|---|
ApprovalType* | Type of Invoice | Should be set to 'Parts' |
CoreAmount | The core amount if applicable | |
IsCoreIncluded* | 'Yes','No' | |
OrderedBy | Name of customer placing order |
Approval Properties - Service
Name | Description | Options |
---|---|---|
ApprovalType* | Type of Invoice | Should be set to 'Service' |
AuthorizedBy | Name of person authorizing charge | |
IsInsuranceInvolved* | Is insurance involved? | 'Yes','No' |
UnitNo* | Unit Number | |
VinNo* | Last 6 digits of VIN |
Approval Properties - Body Shop
Name | Description | Options |
---|---|---|
ApprovalType* | Type of Invoice | Should be set to 'Body Shop' |
AuthorizedBy | Name of person authorizing charge | |
IsInsuranceInvolved* | Is insurance involved? | 'Yes','No' |
UnitNo* | Unit Number | |
VinNo* | Last 6 digits of VIN |
Approval Properties - Lease or Rental
Name | Description | Options |
---|---|---|
ApprovalType* | Type of Invoice | Should be set to 'Lease or Rental' |
Contract* | Contract number of agreement | Limited to 20 chars |
RentEnd* | End date of rental/lease | |
RentStart* | Start date of rental/lease | |
UnitNo | Unit Number | |
UnitRented | Description of unit rented | |
VinNo | Last 6 digits of VIN |
Approval Properties - Other
Name | Description | Options |
---|---|---|
ApprovalType* | Type of Invoice | Should be set to 'Other' |
Other | Comments |
Retrieving Approvals by ID
GET /api/approvals/{id}
To retrieve an approval by ID, send a GET request to the approvals URL. The response body is a JSON or XML Approval object.
Retrieving Approvals by Invoice Number
GET /api/approvals/invoicenumber/{invoicenumber}
To retrieve an approval by invoice number, send a GET request to the approvals/invoicenumber URL. The response body is a JSON or XML Approval object.
Retrieving Approvals by Approval Code
GET /api/approvals/approvalcode/{approvalcode}
To retrieve an approval by approval code, send a GET request to the approvals/approvalcode URL. The response body is a JSON or XML Approval object.
Creating Approvals
POST /api/approvals/
To create an approval, send a POST request to the approvals URL. The request body is a JSON or XML Approval object with type specific properties (Parts, Service, Body Shop, Lease or Rental, Other). The response body is a JSON ApprovalResult object.
Creating Approvals - Parts
POST /api/approvals/
To create a "Parts" approval, send a POST request to the approvals URL. The request body is a JSON or XML Approval object with the Parts type specific properties set. The response body is a JSON or XML ApprovalResult object.
Creating Approvals - Service
POST /api/approvals/
To create a "Service" approval, send a POST request to the approvals URL. The request body is a JSON or XML Approval object with the Service type specific properties set. The response body is a JSON or XML ApprovalResult object.
Creating Approvals - Body Shop
POST /api/approvals/
To create a "Body Shop" approval, send a POST request to the approvals URL. The request body is a JSON or XML Approval object with the Body Shop type specific properties set. The response body is a JSON or XML ApprovalResult object.
Creating Approvals - Lease or Rental
POST /api/approvals/
To create a "Lease or Rental" approval, send a POST request to the approvals URL. The request body is a JSON or XML Approval object with the Lease or Rental type specific properties set. The response body is a JSON or XML ApprovalResult object.
Creating Approvals - Other
POST /api/approvals/
To create a "Other" approval, send a POST request to the approvals URL. The request body is a JSON or XML Approval object with the Other type specific properties set. The response body is a JSON or XML ApprovalResult object.
Updating Approvals
PUT /api/approvals/{id}
To update an approval, send a PUT request to the approvals URL. The {id} parameter is the approval ID and the request body is a JSON or XML Approval object with the updated properties set. The response body is a JSON or XML ApprovalResult object.
Note: At this time, only the Amount, InvoiceNumber (if not previously set), and PONumber properties are available for update.