up

Segment

Actions related to segments in a campaign, used to connect segments to eachother.

Get segment

Facilitates working with segments in SendCastle. A segment can be linked to and from other segments with overrides and filters.

HTTP method: GET
http://api.sendcastle.com/v1/segment/[123]
http://api.sendcastle.com/v1/segment/[all]
cURL example
curl http://api.sendcastle.com/v1/segment/[123] \
	-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json"
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":{
		"UNKNOWN_RETURN_OBJECT: 'segment.'":{
		"id":"1",
		"xxx"
	}
}
Other constraints:
  • Identifier can be an integer or 'all'
  • Requires read access
Change segment

Facilitates working with segments in SendCastle. A segment can be linked to and from other segments with overrides and filters.

HTTP method: POST
http://api.sendcastle.com/v1/segment/[123]
cURL example
curl http://api.sendcastle.com/v1/segment/[123] \
	-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json" \ -X POST
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":true
}
Other constraints:
  • Identifier should be an integer
  • No additional parameters required, unless stated elsewhere
  • Requires write access
  • VC_VRO
Delete segment

Facilitates working with segments in SendCastle. A segment can be linked to and from other segments with overrides and filters.

HTTP method: DELETE
http://api.sendcastle.com/v1/segment/[123]
cURL example
curl http://api.sendcastle.com/v1/segment/[123] \
	--data '{"id":"fnurt"}' \
-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json" \ -X DELETE
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":true
}
Other constraints:
  • Identifier should be an integer
  • Additional parameters required: id
  • Requires delete access
  • VC_VRO
Create segment

Facilitates working with segments in SendCastle. A segment can be linked to and from other segments with overrides and filters.

HTTP method: PUT
http://api.sendcastle.com/v1/segment/[123]
cURL example
curl http://api.sendcastle.com/v1/segment/[123] \
	--data '{"campaign":"fnurt"}' \
-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json" \ -X PUT
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":{
		"id":"1"
	}
}
Other constraints:
  • Identifier should be an integer
  • Additional parameters required: campaign
  • Requires create access
Get recipients in a segment

A segment can contain a filtered version of a datasource, in some cases it can be useful to work with these sets.

HTTP method: GET
http://api.sendcastle.com/v1/segment/[xx]/recipients/[yy]
cURL example
curl http://api.sendcastle.com/v1/segment/[xx]/recipients/[yy] \
	-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json"
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":{
		"UNKNOWN_RETURN_OBJECT: 'segment.recipients'":{
		"id":"1",
		"xxx"
	}
}
Other constraints:
  • Parent identifier cannot be all
  • Requires read access
Get segment connection

A segment connection is a link from one segment (or datasource) to another.

HTTP method: GET
http://api.sendcastle.com/v1/segment/[xx]/connection/[yy]
cURL example
curl http://api.sendcastle.com/v1/segment/[xx]/connection/[yy] \
	-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json"
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":{
		"UNKNOWN_RETURN_OBJECT: 'segment.connection'":{
		"id":"1",
		"xxx"
	}
}
Other constraints:
  • Identifier can be an integer or 'all'
  • Requires read access
Create segment connection

A segment connection is a link from one segment (or datasource) to another.

HTTP method: PUT
http://api.sendcastle.com/v1/segment/[xx]/connection/[yy]
cURL example
curl http://api.sendcastle.com/v1/segment/[xx]/connection/[yy] \
	-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json" \ -X PUT
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":{
		"id":"1"
	}
}
Other constraints:
  • Parent identifier cannot be all
  • Requires create access
  • No additional parameters required, unless stated elsewhere
Delete segment connection

A segment connection is a link from one segment (or datasource) to another.

HTTP method: DELETE
http://api.sendcastle.com/v1/segment/[xx]/connection/[yy]
cURL example
curl http://api.sendcastle.com/v1/segment/[xx]/connection/[yy] \
	-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json" \ -X DELETE
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":true
}
Other constraints:
  • Identifier should be an integer
  • No additional parameters required, unless stated elsewhere
  • Requires delete access
  • VC_VRO
Change segment connection

A segment connection is a link from one segment (or datasource) to another.

HTTP method: POST
http://api.sendcastle.com/v1/segment/[xx]/connection/[yy]
cURL example
curl http://api.sendcastle.com/v1/segment/[xx]/connection/[yy] \
	--data '{"id":"fnurt"}' \
-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json" \ -X POST
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":true
}
Other constraints:
  • Identifier should be an integer
  • Parent identifier cannot be all
  • Requires write access
  • Additional parameters required: id
  • VC_VRONOIT
  • VC_VRO
Get rendered mail for segment

This returns a rendered version of a mail. Not a preview.

HTTP method: GET
http://api.sendcastle.com/v1/segment/[xx]/render/[yy]
cURL example
curl http://api.sendcastle.com/v1/segment/[xx]/render/[yy] \
	-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json"
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":{
		"UNKNOWN_RETURN_OBJECT: 'segment.render'":{
		"id":"1",
		"xxx"
	}
}
Other constraints:
  • Parent identifier cannot be all
  • Requires read access
put.segment.copyable (!)

No description yet.

HTTP method: PUT
http://api.sendcastle.com/v1/segment/[xx]/copyable/[yy]
cURL example
curl http://api.sendcastle.com/v1/segment/[xx]/copyable/[yy] \
	--data '{"source":"fnurt","destination":"fnurt"}' \
-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json" \ -X PUT
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":{
		"id":"1"
	}
}
Other constraints:
  • Parent identifier cannot be all
  • Identifier should be an integer
  • Requires create access
  • Additional parameters required: source, destination
post.segment.copyable (!)

No description yet.

HTTP method: POST
http://api.sendcastle.com/v1/segment/[xx]/copyable/[yy]
cURL example
curl http://api.sendcastle.com/v1/segment/[xx]/copyable/[yy] \
	--data '{"source":"fnurt","destination":"fnurt","direction":"fnurt"}' \
-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json" \ -X POST
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":true
}
Other constraints:
  • Parent identifier cannot be all
  • Identifier should be an integer
  • Requires create access
  • Additional parameters required: source, destination, direction
  • Parent identifier is primary identifier
  • VC_VRO
delete.segment.copyable (!)

No description yet.

HTTP method: DELETE
http://api.sendcastle.com/v1/segment/[xx]/copyable/[yy]
cURL example
curl http://api.sendcastle.com/v1/segment/[xx]/copyable/[yy] \
	--data '{"source":"fnurt"}' \
-H "Authorization: Bearer YOUR_API_SECRET_HERE" \
-H "Content-Type: application/json" \ -X DELETE
Example of result
{
	"responseId":"50cef8fcaxxxx",
	"version":1,
	"success":true,
	"data":true
}
Other constraints:
  • Parent identifier cannot be all
  • Identifier should be an integer
  • Requires create access
  • Additional parameters required: source
  • Parent identifier is primary identifier
  • VC_VRO