Resource Definitions:Lists/ID

From API Documentation

(Difference between revisions)
Jump to: navigation, search
(Created page with 'The lists/ID resource is an individual distribution list associated with your agent account. '''''Example URI:''''' <nowiki>http://api.rezora.com/v1/lists/1234</nowiki> Availa…')
 
(3 intermediate revisions not shown)
Line 1: Line 1:
-
The lists/ID resource is an individual distribution list associated with your agent account.
+
The ''lists/ID'' resource is an individual distribution list associated with your agent account, where "ID" is the list's list_id number.
 +
 
 +
Each agent account has one special list, known as the Primary Sphere. This list has a list_type value of 1, while all other lists have a list_type value of 0. The Primary Sphere cannot be updated or deleted. The delete all functionality deletes all lists with a list_type value of 0, but leaves the Primary Sphere in tact.
  '''''Example URI:''''' <nowiki>http://api.rezora.com/v1/lists/1234</nowiki>
  '''''Example URI:''''' <nowiki>http://api.rezora.com/v1/lists/1234</nowiki>
Line 6: Line 8:
== GET ==
== GET ==
-
Returns an individual distribution. The distribution list record includes the following fields:
+
Returns an individual distribution list. The distribution list record includes the following fields:
* list_id
* list_id
Line 140: Line 142:
</div>
</div>
[[Category:Resource Definitions]]
[[Category:Resource Definitions]]
 +
[[Category:Agent Resources]]

Latest revision as of 04:36, 3 August 2010

The lists/ID resource is an individual distribution list associated with your agent account, where "ID" is the list's list_id number.

Each agent account has one special list, known as the Primary Sphere. This list has a list_type value of 1, while all other lists have a list_type value of 0. The Primary Sphere cannot be updated or deleted. The delete all functionality deletes all lists with a list_type value of 0, but leaves the Primary Sphere in tact.

Example URI: http://api.rezora.com/v1/lists/1234

Available methods are:

Contents

GET

Returns an individual distribution list. The distribution list record includes the following fields:

  • list_id
  • list_name
  • list_date
  • list_type - possible values: 0, 1 (cannnot delete)

Example Responses

XML Response

<?xml version="1.0" encoding="UTF-8"?>
<lists version="1.0">
 <list>
  <list_id>1234</list_id>
  <list_name>Current Prospects</list_name>
  <list_date>2010-07-21 16:28:52</list_date>
  <list_type>0</list_type>
 </list>
</lists>

JSON Response

[
 {
  "list_id":"1234",
  "list_name":"Current Prospects",
  "list_date":"2010-07-21 16:28:52",
  "list_type":"0"
 }
]

CSV Response

"list_id"|"list_name"|"list_date"|"list_type"
"1234"|"Current Prospects"|"2010-07-21 16:28:52"|"0"

PUT

Updates an existing distribution list, and returns a success code. Note the you CANNOT update a Primary Sphere list (list_type = 1). You may include the following fields (required fields marked with a red asterisk (*)):

  • list_name * (must be unique)

Example Request Data

XML Request

<?xml version="1.0" encoding="UTF-8"?>
<data>
 <list_name>Hot Leads</list_name>
</data>

JSON Request

{
 "data":{
  "list_name":"Hot Leads"
 }
}

TEXT Request

list_name=Hot+Leads

Example Response Data

XML Response

<?xml version="1.0" encoding="UTF-8"?>
<lists version="1.0">
 <list>
  <status>200</status>
 </list>
</lists>

JSON Response

[
 {
  "status":"200"
 }
]

CSV Response

"status"
"200"

DELETE

Permanently removes an individual distribution list, and returns a success code. Note the you CANNOT delete a Primary Sphere list (list_type = 1).

Example Response Data

XML Response

<?xml version="1.0" encoding="UTF-8"?>
<lists version="1.0">
 <list>
  <status>200</status>
 </list>
</lists>

JSON Response

[
 {
  "status":"200"
 }
]

CSV Response

"status"
"200"
Personal tools