Tag Groups are a saved lists of contacts specified by database users. Outlined below are various GET methods that fetch Tag Group related data.
If you would like to retrieve the list of User-Defined Fields for a database, you should take a look at our '/settings/taggroups' method Tag Groups Fetch
The purpose of each of the methods are outlined below.
Method Type: GET
returns a Tag Group record by TagID
'/taggroups/{tagid}'
Tag Group's Contacts by TagID Fetch
Method Type: GET
returns a list of contacts associated with a tag group.
'/taggroups/{tagid}/contacts'
Method Type: GET
returns a list of tag groups associated associated with a ContactID.
'/contacts/{contactid}/taggroups'
The URI '/taggroups/{tagid}', when paired with the Method Type 'GET', returns a specific Tag Group record.
https://api2.redtailtechnology.com/crm/v1/rest/taggroups/7315
Below is a sample request in C# using our URI, sample credentials, and the method type. The content type "text/json" work equally well.
HttpWebRequest req = (HttpWebRequest)HttpWebRequest.Create("https://api2.redtailtechnology.com/crm/v1/rest/taggroups/7315"); req.Headers[System.Net.HttpRequestHeader.Authorization] = "Basic " + Convert.ToBase64String(System.Text.Encoding.Default.GetBytes("6C135EDF-C37C-4039-AEF3-5DFC079F9E6A:Statementone:sonedemo")); req.Method = "GET"; req.ContentType = "text/xml";
//and here's the response stream.
HttpWebResponse resp = (HttpWebResponse)req.GetResponse();
System.IO.StreamReader sr = new System.IO.StreamReader(resp.GetResponseStream());
The corresponding response(xml) will be similar to the following.
The URI '/taggroups/{tagid}/contacts', when paired with the Method Type 'GET', returns a List of Contacts associated with a Tag Group.
'taggroups/{tagid}/contacts
https://api2.redtailtechnology.com/crm/v1/rest/taggroups/7315/contacts
Below is a sample request in C# using our URI, sample credentials, and the method type. The content type "text/json" work equally well.
HttpWebRequest req = (HttpWebRequest)HttpWebRequest.Create("https://api2.redtailtechnology.com/crm/v1/rest/taggroups/7315/contacts"); req.Headers[System.Net.HttpRequestHeader.Authorization] = "Basic " + Convert.ToBase64String(System.Text.Encoding.Default.GetBytes("6C135EDF-C37C-4039-AEF3-5DFC079F9E6A:Statementone:sonedemo")); req.Method = "GET"; req.ContentType = "text/xml";
//and here's the response stream.
HttpWebResponse resp = (HttpWebResponse)req.GetResponse();
System.IO.StreamReader sr = new System.IO.StreamReader(resp.GetResponseStream());
The corresponding response(xml) will be similar to the following.
The URI '/contacts/{contactid}/taggroups', when paired with the Method Type 'GET', returns a List of Tag Groups associated with a Contact
A popular Contact used for testing in our test database is 'Mary Investor'. So we will use her ContactID in the URI below..
'contacts/{contactid}/taggroups'
https://api2.redtailtechnology.com/crm/v1/rest/contacts/384843/taggroups
Below is a sample request in C# using our URI, sample credentials, and the method type. The content type "text/json" work equally well.
HttpWebRequest req = (HttpWebRequest)HttpWebRequest.Create("https://api2.redtailtechnology.com/crm/v1/rest/contacts/384843/taggroups"); req.Headers[System.Net.HttpRequestHeader.Authorization] = "Basic " + Convert.ToBase64String(System.Text.Encoding.Default.GetBytes("6C135EDF-C37C-4039-AEF3-5DFC079F9E6A:Statementone:sonedemo")); req.Method = "GET"; req.ContentType = "text/xml";
//and here's the response stream.
HttpWebResponse resp = (HttpWebResponse)req.GetResponse();
System.IO.StreamReader sr = new System.IO.StreamReader(resp.GetResponseStream());
The corresponding response(xml) will be similar to the following.
Comments