Variable | Type | Description |
---|---|---|
list_id | string|int | The ID of the list in which to save the subscription |
string | The email of the subscriber | |
firstname | string|null | The firstname of the subscriber, can be null. |
lastname | string|null | The lastname of the subscriber, can be null. |
ip | string | The ip address of the subscriber |
props | struct|null | Hash array with props (can be later used to build segment criteria) |
options | struct|null | Hash array with options for this init subscribe. Valid keys are:
|
Parameter | Description |
---|---|
int | The action id |
curl "https://ssl.newsman.app/api/1.2/rest/your_user_id/your_api_key/subscriber.initSubscribe.json?list_id=my_list_id&email=test%40example.com&firstname=null&lastname=null&ip=the_ip_address&props[some_prop]=some_value&options[segments][]=15002"
3012
Code | Message | Description |
---|---|---|
407 | Missing required param list_id | list_id param is required |
407 | Missing required param email | email param is required |
407 | Missing required param firstname | firstname param is required |
407 | Missing required param lastname | lastname param is required |
407 | Missing required param ip | ip param is required |
407 | Missing required param props | props param is required |
407 | Missing required param options | options param is required |
101 | Not allowed for list_id = %s | Invalid access to subscriber list_id |
108 | List %s has been deleted | List ID belongs to a list which has been deleted |
122 | Invalid IP received $ip | The IP is invalid |
126 | Optout email received %s | Optout email. Only initsubscribe is allowed. |
123 | Invalid email address %s. | The email is not valid |
10001 | Cannot use both template_id and form_id | Cannot use both template_id and form_id in options |
128 | Too many requests for this subscriber. Can only send once per 10 minutes | Can only send once per 10 minutes to the same email |
144 | Cannot subscribe to this segment | Cannot subscribe to this segment |
201 | Internal Error: %s | A database error occurred |
{ "err": true, "message": "Missing required param list_id", "code": 407 }
{ "err": true, "message": "Missing required param email", "code": 407 }
{ "err": true, "message": "Missing required param firstname", "code": 407 }
{ "err": true, "message": "Missing required param lastname", "code": 407 }
{ "err": true, "message": "Missing required param ip", "code": 407 }
{ "err": true, "message": "Missing required param props", "code": 407 }
{ "err": true, "message": "Missing required param options", "code": 407 }
{ "err": true, "message": "Invalid IP received 127.0.0.1", "code": 122 }
{ "err": true, "message": "Too many requests for this subscriber. Can only send once per 10 minutes", "code": 128 }
{ "err": true, "message": "Subscriber is already subscribed", "code": 130 }