Submit a referral
POST
/referrals
const url = 'https://api.ccswebservices.org/v1/referrals';const options = { method: 'POST', headers: {apiKey: '<apiKey>', 'Content-Type': 'application/json'}, body: '{"firstName":"Testxxx-Firstname","lastName":"Testxxx-Lastname","phoneNumber":"+16045559999","emailAddress":"Testxxx@example.com","city":"Vancouver","province":"BC","referralPartner":"Testxxx-Referral-Partner","notes":"Client called in requesting debt consolidation information"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.ccswebservices.org/v1/referrals \ --header 'Content-Type: application/json' \ --header 'apiKey: <apiKey>' \ --data '{ "firstName": "Testxxx-Firstname", "lastName": "Testxxx-Lastname", "phoneNumber": "+16045559999", "emailAddress": "Testxxx@example.com", "city": "Vancouver", "province": "BC", "referralPartner": "Testxxx-Referral-Partner", "notes": "Client called in requesting debt consolidation information" }'Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Header Parameters
Section titled “Header Parameters ” apiKey
required
string
Subscription key for API access. Issued by the API administrator. Request access through the developer portal or by the contact email.
Request Body required
Section titled “Request Body required ” Media type application/json
object
firstName
required
string
Example
Testxxx-Firstname lastName
required
string
Example
Testxxx-Lastname phoneNumber
required
Phone number in E.164 format (e.g. +16045559999). Must include country code.
string format: phone
Example
+16045559999 emailAddress
required
string format: email
Example
Testxxx@example.com city
required
string
Example
Vancouver province
required
string
Example
BC referralPartner
required
Must be the partner identifier provided by the API administrator when given API key. Any other value returns 400. The test value can be used in development or sandbox environments.
string
Example
Testxxx-Referral-Partner notes
string
Example
Client called in requesting debt consolidation informationResponses
Section titled “ Responses ”Referral submitted successfully
Invalid request — missing required fields, invalid phone number format (must be E.164), or referralPartner is not an allowed value
Unauthorized - missing or invalid subscription key