You've Got Leads API

Making your CRM data work for you.

Leads

The lead endpoint provides access to a single community's leads, including contact information, resident profile, sources, and tasks.

There are no required fields when posting a lead. You should provide a name and a way to contact each lead.

Requests

Name Method Description
/api/properties/{PropertyId}/leads GET Search for leads associated with this community
/api/properties/{PropertyId}/leads POST Insert a new lead for this community into their YGL account
/api/properties/{PropertyId}/leads/{LeadId} GET Retrieve information about a specific lead associated with the community

Request/Response Objects

The main object associated with the endpoint is the Lead object. The Lead object contains some information and references to other object types explained below.

Leads

Name Type Description
LeadId int This is the unique identifier for the lead and is only available on GET requests
ContactId int The unique identifier for the primary contact, only available on GET requests
SecondaryContactId int The unique identifier for the secondary contact, only available on GET requests
AddedOn DateTime? The date the lead was added, or the date the user chose as the added on date.
Associate string (45) The YGL username of the user assigned to this lead
BudgetMax int The code for the maximum budget of the potential resident. Available options are: 0 (Not Sure), 1000 (Under $1,000), 1500 ($1,500), 2000 ($2,000), 3000 ($3,000), 4000 ($4,000), and 4001 (Over $4,000).
BudgetMin int The code for the minimum budget of the potential resident. Available options are: 0 (Not Sure), 1000 (Under $1,000), 1500 ($1,500), 2000 ($2,000), 3000 ($3,000), 4000 ($4,000), and 4001 (Over $4,000).
CallCenterId string (50) Used by referral sources to enter their unique ID for a lead
CreatedOn DateTime The date the lead was created. This field is only available for GET requests.
DischargePlannerId int Used only for the skilled nursing module
FamilyStatusId int The code for the current family status
FundingType int The code associated with the funding type for this lead
InquiryMethod string (30) The method by which the lead originally inquired. Possible values are null, none, Email, Fax, Mail In, Corp. Phone In, Phone In, Walk In, and Web.
LeadResident LeadResident An object that contains information about the potential resident's elder care search
Notes LeadNotes The notes associated with this lead.
Ownership string (1) A code representing whether the lead owns their own home. Possible values are " " (Unknown), "O" (Own), and "R" Rent.
PrimaryContact Contact An object containing contact information for the primary contact
Priority int A code associated with the lead priority (typically Hot, Warm, Cold)
ReferralSources Array of ReferralSource A list of ReferralSource objects, ordered by rank. Required for referral source users.
ResidentContact Contact An object containing contact information for the potential resident
SecondaryContact Contact An object containing contact information for a secondary contact person, if any
SecondFundingType int A code representing a secondary funding type. Skilled Nursing only.
StatusId int A code repesenting the current status of the lead. Read only, available on GET requests. See Lead Statuses for documentation on retrieving StatusId values.
UserName string (10) A unique string identifying the community the lead belongs to. Only available on GET requests.
Veteran string (1) A code representing the potential resident's veteran status, Allowable values are "U" (Unknown), "Y" (Yes), and "N" (No).

Contact

Name Type Description
ContactId int This is the unique identifier for the contact, only available on GET requests
AddressId int The unique identifier for the Address object related to this contact, only available on GET requests
Address Address An object representing the address and other contact information for the person
AllowContact boolean Does this contact with to be contacted
Dob DateTime The date of birth for the person, only available for a Resident contact
FirstName string (45)
Gender string (1) Code representing the person's gender, only available for a Resident contact
IsInquirer boolean True if primary contact, otherwise null or false
LastName string (45)
MaritalStatus string (1) Code representing the marital status of the person, only for Resident contacts
RelationToResident int Code representing the relation of the contact to the potential resident, only available for non-Resident contacts

Contact Notes

Name Type Description
Notes string The notes.
UpdatedBy string The username of the user who last updated the notes. Optional on a POST; will default to the username used as the lead creator.
UpdatedOn Date/Time The date and time the note was last updated. Not avaiable on a POST.

Address

Name Type Description
AddressId int The unique identifier for this address object, only available on GET requests
Address1 string (50) The first address line
Address2 string (50) The second address line
AllowMailings bool Does the related contact allow mailings
City string (50)
ContactPreference int Code representing how the contact prefers to be contacted
ContactTimePref int Code representing the best time to contact the person
Country string (2) The country code
Email string (255)
Fax string (18)
PhoneCell string (18)
PhoneHome string (18)
PhoneWork string (18)
State string (2) The state or province code
UpdatedOn DateTime The date and time the address was last updated.
Zip string (10)

Resident

Name Type Description
Age int?
Bathing int? Assistance needed; None = 1, Some = 2, Full = 3, null = not specified
CareLevel int? See Care Level
CurrentLivingSituation int? See Current Living Situation
DateOfBirth DateTime?
Dressing int? Assistance needed; None = 1, Some = 2, Full = 3, null = not specified
Driving int? Assistance needed; None = 1, Some = 2, Full = 3, null = not specified
Eating int? Assistance needed; None = 1, Some = 2, Full = 3, null = not specified
EstimatedAdmitDate DateTime? Skilled Nursing module only
Hair int? Assistance needed; None = 1, Some = 2, Full = 3, null = not specified
HotButtons string (1000) Plain text field to explain things that are important to the potential resident in their care search
IsDiabetic bool? Does the potential resident need diabetic injections?
Laundry int? Assistance needed; None = 1, Some = 2, Full = 3, null = not specified
MaritalStatus string (1) M = Married, S = Single, D = Divorced, W = Widowed, null = not specified
Meals int? Assistance needed; None = 1, Some = 2, Full = 3, null = not specified
Medication int? Assistance needed; None = 1, Some = 2, Full = 3, null = not specified
MemoryLoss int? See Memory Loss
Physician string (75) Skilled Nursing module only
Pref string (255) Comma delimited list of amenity preference codes. See Amenities.
TimeFrame int? Time frame person anticipates making a decision. Allowable values are: 0 (Unknown), 8 (1-7 Days), 1 (1-2 Weeks), 2 (3-4 Weeks), 3 (1-2 Months), 4 (3-4 Months), 5 (5-6 Months), 6 (Over 6 Months), 7 (Not Sure).
Toileting int? Assistance needed; None = 1, Some = 2, Full = 3, null = not specified
UnitTypeId string (100) Comma delimited list of ID's indicating what the potential reisdent's room preference is. See Unit Type.
Walking int? Method of ambulation, see Ambulation.

ReferralSource

Name Type Description
LeadSourceId int The unique identifier for the source
LeadSourceName string Coming Soon!
LeadSourceRank int The rank of this source, as compared to other sources attributed to this lead.

Sample GET Requests

https://www.youvegotleads.com/api/properties/95774/leads
https://www.youvegotleads.com/api/properties/95774/leads?$filter=PrimaryContact/FirstName+eq+'Mico'
https://www.youvegotleads.com/api/properties/95774/leads?$filter=BudgetMax+gt+2999
https://www.youvegotleads.com/api/properties/95774/leads?$filter=LeadId+eq+14308580

Sample GET Response


[
   {
      "Priority":0,
      "Associate":"ApiTest1",
      "InquiryMethod":"email",
      "BudgetMax":12,
      "BudgetMin":11,
      "CallCenterId":null,
      "FamilyStatusId":-1,
      "LeadId":14308580,
      "FundingType":null,
      "SecondFundingType":null,
      "UserName":"Guest5",
      "DischargePlannerId":null,
      "Ownership":null,
      "Veteran":null,
      "PrimaryContact":{
         "FirstName":"Mico",
         "LastName":"Json",
         "AllowContact":true,
         "IsInquirer":true,
         "RelationToResident":0,
         "ContactId":46639508,
         "DateOfBirth":null,
         "Gender":null,
         "MaritalStatus":null,
         "Address":{
            "Address1":"stree no1",
            "Address2":"stree no2",
            "City":"DC",
            "State":"DC",
            "Zip":"001203",
            "Country":"UK",
            "AllowMailings":true,
            "PhoneHome":"11443455",
            "PhoneCell":"1124245",
            "PhoneWork":"7864781",
            "Fax":"101-21244",
            "Email":"Tes@gmail.com",
            "DoNotCallCell":true,
            "DoNotCallHome":true,
            "DoNotCallWork":false,
            "AddressId":40646593,
            "ContactPreference":null,
            "ContactTimePref":null
         }
      },
      "ResidentContact":{
         "FirstName":"Jhon",
         "LastName":"Luies",
         "AllowContact":true,
         "IsInquirer":true,
         "RelationToResident":0,
         "ContactId":46639509,
         "DateOfBirth":null,
         "Gender":"F",
         "MaritalStatus":"M",
         "Address":{
            "Address1":"stree no1",
            "Address2":"stree no2",
            "City":"DC",
            "State":"DC",
            "Zip":"001203",
            "Country":"UK",
            "AllowMailings":true,
            "PhoneHome":"11443455",
            "PhoneCell":"1124245",
            "PhoneWork":"7864781",
            "Fax":"101-21244",
            "Email":"Tes@gmail.com",
            "DoNotCallCell":true,
            "DoNotCallHome":true,
            "DoNotCallWork":false,
            "AddressId":40646594,
            "ContactPreference":null,
            "ContactTimePref":null
         }
      },
      "SecondaryContact":{
         "FirstName":"Jhon",
         "LastName":"Luies",
         "AllowContact":true,
         "IsInquirer":true,
         "RelationToResident":0,
         "ContactId":46639510,
         "DateOfBirth":null,
         "Gender":null,
         "MaritalStatus":null,
         "Address":{
            "Address1":"stree no1",
            "Address2":"stree no2",
            "City":"DC",
            "State":"DC",
            "Zip":"001203",
            "Country":"UK",
            "AllowMailings":true,
            "PhoneHome":"11443455",
            "PhoneCell":"1124245",
            "PhoneWork":"7864781",
            "Fax":"101-21244",
            "Email":"Tes@gmail.com",
            "DoNotCallCell":true,
            "DoNotCallHome":true,
            "DoNotCallWork":false,
            "AddressId":40646595,
            "ContactPreference":null,
            "ContactTimePref":null
         }
      },
      "LeadResident":{
         "Age":65,
         "Bathing":1,
         "CareLevel":null,
         "CurrentLivingSituation":null,
         "Dob":null,
         "Dressing":0,
         "Driving":0,
         "Eating":1,
         "EstimatedAdmitDate":null,
         "Hair":1,
         "HotButtons":null,
         "IsDiabetic":true,
         "Laundry":0,
         "MaritalStatus":"M",
         "Meals":1,
         "MemoryLoss":null,
         "Medication":1,
         "Physician":null,
         "Pref":null,
         "TimeFrame":1,
         "Toileting":0,
         "UnitTypeId":null,
         "Walking":1,
         "DateOfBirth":null
      }
   },
   {
      "Priority":0,
      "Associate":"ApiTest1",
      "InquiryMethod":"email",
      "BudgetMax":12,
      "BudgetMin":11,
      "CallCenterId":null,
      "FamilyStatusId":-1,
      "LeadId":14308581,
      "FundingType":null,
      "SecondFundingType":null,
      "UserName":"Guest5",
      "DischargePlannerId":null,
      "Ownership":null,
      "Veteran":null,
      "PrimaryContact":{
         "FirstName":"Mico",
         "LastName":"Json",
         "AllowContact":true,
         "IsInquirer":true,
         "RelationToResident":0,
         "ContactId":46639511,
         "DateOfBirth":null,
         "Gender":null,
         "MaritalStatus":null,
         "Address":{
            "Address1":"stree no1",
            "Address2":"stree no2",
            "City":"DC",
            "State":"DC",
            "Zip":"001203",
            "Country":"UK",
            "AllowMailings":true,
            "PhoneHome":"11443455",
            "PhoneCell":"1124245",
            "PhoneWork":"7864781",
            "Fax":"101-21244",
            "Email":"Tes@gmail.com",
            "DoNotCallCell":true,
            "DoNotCallHome":true,
            "DoNotCallWork":false,
            "AddressId":40646596,
            "ContactPreference":null,
            "ContactTimePref":null
         }
      },
      "ResidentContact":{
         "FirstName":"Jhon",
         "LastName":"Luies",
         "AllowContact":true,
         "IsInquirer":true,
         "RelationToResident":0,
         "ContactId":46639512,
         "DateOfBirth":null,
         "Gender":"F",
         "MaritalStatus":"M",
         "Address":{
            "Address1":"stree no1",
            "Address2":"stree no2",
            "City":"DC",
            "State":"DC",
            "Zip":"001203",
            "Country":"UK",
            "AllowMailings":true,
            "PhoneHome":"11443455",
            "PhoneCell":"1124245",
            "PhoneWork":"7864781",
            "Fax":"101-21244",
            "Email":"Tes@gmail.com",
            "DoNotCallCell":true,
            "DoNotCallHome":true,
            "DoNotCallWork":false,
            "AddressId":40646597,
            "ContactPreference":null,
            "ContactTimePref":null
         }
      },
      "SecondaryContact":{
         "FirstName":"Jhon",
         "LastName":"Luies",
         "AllowContact":true,
         "IsInquirer":true,
         "RelationToResident":0,
         "ContactId":46639513,
         "DateOfBirth":null,
         "Gender":null,
         "MaritalStatus":null,
         "Address":{
            "Address1":"stree no1",
            "Address2":"stree no2",
            "City":"DC",
            "State":"DC",
            "Zip":"001203",
            "Country":"UK",
            "AllowMailings":true,
            "PhoneHome":"11443455",
            "PhoneCell":"1124245",
            "PhoneWork":"7864781",
            "Fax":"101-21244",
            "Email":"Tes@gmail.com",
            "DoNotCallCell":true,
            "DoNotCallHome":true,
            "DoNotCallWork":false,
            "AddressId":40646598,
            "ContactPreference":null,
            "ContactTimePref":null
         }
      },
      "LeadResident":{
         "Age":65,
         "Bathing":1,
         "CareLevel":null,
         "CurrentLivingSituation":null,
         "Dob":null,
         "Dressing":0,
         "Driving":0,
         "Eating":1,
         "EstimatedAdmitDate":null,
         "Hair":1,
         "HotButtons":null,
         "IsDiabetic":true,
         "Laundry":0,
         "MaritalStatus":"M",
         "Meals":1,
         "MemoryLoss":null,
         "Medication":1,
         "Physician":null,
         "Pref":null,
         "TimeFrame":1,
         "Toileting":0,
         "UnitTypeId":null,
         "Walking":1,
         "DateOfBirth":null
      }
   }
]   

Sample POST Request

You can omit any fields you are not using when passing the JSON body of your POST.

https://www.youvegotleads.com/api/properties/95774/leads

{
    PrimaryContact: {
    FirstName: "TestFirst",
    LastName: "TestLast",
    Address: {
        Email: "testfirst.testlast@example.com",
        PhoneCell: "555-848-4857"
        }
    }
}

Sample POST Response

You will receive a status code of 201 back from the server if the lead was successfully created. Any other response such as 500 or 400 means that the lead was not created. You will need to inspect the response to determine why the lead was not created.


{
   "LeadId":14308586,
   "AddedOn":"2014-05-06T00:00:00",
   "Priority":null,
   "FundingType":null,
   "SecondFundingType":null,
   "DischargePlannerId":null,
   "BudgetMax":null,
   "BudgetMin":null,
   "FamilyStatusId":-1,
   "Ownership":null,
   "Veteran":null,
   "Associate":"ApiTest1",
   "InquiryMethod":null,
   "CallCenterId":null,
   "PrimaryContact":{
      "ContactId":46639526,
      "FirstName":"TestFirst",
      "LastName":"TestLast",
      "AllowContact":null,
      "IsInquirer":null,
      "RelationToResident":0,
      "Address":{
         "AddressId":40646599,
         "Address1":null,
         "Address2":null,
         "City":null,
         "State":null,
         "Zip":null,
         "Country":null,
         "AllowMailings":null,
         "PhoneHome":null,
         "PhoneWork":null,
         "PhoneCell":"555-848-4857",
         "Fax":null,
         "Email":"testfirst.testlast@example.com",
         "DoNotCallHome":null,
         "DoNotCallWork":null,
         "DoNotCallCell":null,
         "ContactTimePref":null,
         "ContactPreference":null
      },
      "Gender":null,
      "MaritalStatus":null,
      "DateOfBirth":null
   },
   "ResidentContact":{
      "ContactId":46639527,
      "FirstName":null,
      "LastName":null,
      "AllowContact":null,
      "IsInquirer":null,
      "RelationToResident":0,
      "Address":null,
      "Gender":null,
      "MaritalStatus":null,
      "DateOfBirth":null
   },
   "SecondaryContact":{
      "ContactId":46639528,
      "FirstName":null,
      "LastName":null,
      "AllowContact":null,
      "IsInquirer":null,
      "RelationToResident":0,
      "Address":null,
      "Gender":null,
      "MaritalStatus":null,
      "DateOfBirth":null
   },
   "LeadResident":{
      "MaritalStatus":null,
      "CareLevel":null,
      "TimeFrame":0,
      "EstimatedAdmitDate":null,
      "HotButtons":null,
      "Age":null,
      "DateOfBirth":null,
      "CurrentLivingSituation":null,
      "MemoryLoss":null,
      "Walking":null,
      "Laundry":null,
      "Eating":null,
      "Toileting":null,
      "Bathing":null,
      "Hair":null,
      "Dressing":null,
      "Meals":null,
      "Medication":null,
      "Driving":null,
      "IsDiabetic":null,
      "Pref":null,
      "UnitTypeId":null,
      "Dob":null,
      "Physician":null
   },
   "UserName":"Guest5"
}    


Sample PUT Request

https://www.youvegotleads.com/api/properties/95774/leads

{
   "LeadId":14308586,
   "AddedOn":"2014-05-06T00:00:00",
   "Priority":null,
   "FundingType":null,
   "SecondFundingType":null,
   "DischargePlannerId":null,
   "BudgetMax":null,
   "BudgetMin":null,
   "FamilyStatusId":-1,
   "Ownership":null,
   "Veteran":null,
   "Associate":"ApiTest1",
   "InquiryMethod":null,
   "CallCenterId":null,
   "PrimaryContact":{
      "ContactId":46639526,
      "FirstName":"TestFirst",
      "LastName":"TestLast",
      "AllowContact":null,
      "IsInquirer":null,
      "RelationToResident":0,
      "Address":{
         "AddressId":40646599,
         "Address1":null,
         "Address2":null,
         "City":null,
         "State":null,
         "Zip":null,
         "Country":null,
         "AllowMailings":null,
         "PhoneHome":null,
         "PhoneWork":null,
         "PhoneCell":"555-848-4857",
         "Fax":null,
         "Email":"testfirst.testlast@example.com",
         "DoNotCallHome":null,
         "DoNotCallWork":null,
         "DoNotCallCell":null,
         "ContactTimePref":null,
         "ContactPreference":null
      },
      "Gender":null,
      "MaritalStatus":null,
      "DateOfBirth":null
   },
   "ResidentContact":{
      "ContactId":46639527,
      "FirstName":null,
      "LastName":null,
      "AllowContact":null,
      "IsInquirer":null,
      "RelationToResident":0,
      "Address":null,
      "Gender":null,
      "MaritalStatus":null,
      "DateOfBirth":null
   },
   "SecondaryContact":{
      "ContactId":46639528,
      "FirstName":null,
      "LastName":null,
      "AllowContact":null,
      "IsInquirer":null,
      "RelationToResident":0,
      "Address":null,
      "Gender":null,
      "MaritalStatus":null,
      "DateOfBirth":null
   },
   "LeadResident":{
      "MaritalStatus":null,
      "CareLevel":null,
      "TimeFrame":0,
      "EstimatedAdmitDate":null,
      "HotButtons":null,
      "Age":null,
      "DateOfBirth":null,
      "CurrentLivingSituation":null,
      "MemoryLoss":null,
      "Walking":null,
      "Laundry":null,
      "Eating":null,
      "Toileting":null,
      "Bathing":null,
      "Hair":null,
      "Dressing":null,
      "Meals":null,
      "Medication":null,
      "Driving":null,
      "IsDiabetic":null,
      "Pref":null,
      "UnitTypeId":null,
      "Dob":null,
      "Physician":null
   },
   "UserName":"Guest5"
}    

Sample PUT Response

You will receive a status code of 201 back from the server if the lead was successfully updated. Any other response such as 500 or 400 means that the lead was not updated. You will need to inspect the response to determine why the lead was not updated.


{
   "LeadId":14308586,
   "AddedOn":"2014-05-06T00:00:00",
   "Priority":null,
   "FundingType":null,
   "SecondFundingType":null,
   "DischargePlannerId":null,
   "BudgetMax":null,
   "BudgetMin":null,
   "FamilyStatusId":-1,
   "Ownership":null,
   "Veteran":null,
   "Associate":"ApiTest1",
   "InquiryMethod":null,
   "CallCenterId":null,
   "PrimaryContact":{
      "ContactId":46639526,
      "FirstName":"TestFirst",
      "LastName":"TestLast",
      "AllowContact":null,
      "IsInquirer":null,
      "RelationToResident":0,
      "Address":{
         "AddressId":40646599,
         "Address1":null,
         "Address2":null,
         "City":null,
         "State":null,
         "Zip":null,
         "Country":null,
         "AllowMailings":null,
         "PhoneHome":null,
         "PhoneWork":null,
         "PhoneCell":"555-848-4857",
         "Fax":null,
         "Email":"testfirst.testlast@example.com",
         "DoNotCallHome":null,
         "DoNotCallWork":null,
         "DoNotCallCell":null,
         "ContactTimePref":null,
         "ContactPreference":null
      },
      "Gender":null,
      "MaritalStatus":null,
      "DateOfBirth":null
   },
   "ResidentContact":{
      "ContactId":46639527,
      "FirstName":null,
      "LastName":null,
      "AllowContact":null,
      "IsInquirer":null,
      "RelationToResident":0,
      "Address":null,
      "Gender":null,
      "MaritalStatus":null,
      "DateOfBirth":null
   },
   "SecondaryContact":{
      "ContactId":46639528,
      "FirstName":null,
      "LastName":null,
      "AllowContact":null,
      "IsInquirer":null,
      "RelationToResident":0,
      "Address":null,
      "Gender":null,
      "MaritalStatus":null,
      "DateOfBirth":null
   },
   "LeadResident":{
      "MaritalStatus":null,
      "CareLevel":null,
      "TimeFrame":0,
      "EstimatedAdmitDate":null,
      "HotButtons":null,
      "Age":null,
      "DateOfBirth":null,
      "CurrentLivingSituation":null,
      "MemoryLoss":null,
      "Walking":null,
      "Laundry":null,
      "Eating":null,
      "Toileting":null,
      "Bathing":null,
      "Hair":null,
      "Dressing":null,
      "Meals":null,
      "Medication":null,
      "Driving":null,
      "IsDiabetic":null,
      "Pref":null,
      "UnitTypeId":null,
      "Dob":null,
      "Physician":null
   },
   "UserName":"Guest5"
}