Follow

Code Examples

The FTP API requires two separate files to execute the commands.    The following example provides basic contents for each file.  

File Examples

The Data File contains the Header and the Commands to run.  It must be saved with a .dat extension, for example myrealm_202003_subscribes.dat:

realm=myrealm
password=mypass
cmd=sub&list_id=42&data=email^mail@domain.com
cmd=unsub&list_id=42&data=email^mail@domain.com

The Signal File should be empty.  It must be named the same as the Data file, but be save with the extension .sig, for example  myrealm_202003_subscribes.sig:

<Empty File>

An alternate data file example using one of the four possible, non-default API Clients* for a realm:

realm=myrealm
password=mypassalt
api_client=myclient
client_auth=myclientauth
cmd=sub&list_id=42&data=email^mail@domain.com
cmd=unsub&list_id=42&data=email^mail@domain.com

Header Template

Use the following as a template for your .dat file headers.  Notice there are no spaces between the commands and the values.

realm=[realm_name]
password=[authentication_code]
api_client=[client_name]
client_auth=[client_authentication_code]
confirmation_email=[email_address;email_address2;email_addressn]
verbose=[0,false,1,true]
description=[text_string]
optout=[0,false,1,true]
universal=[0,false,1,true]  //broadcasters only
force_optout=[0,false,1,true]
force_sub=[0,false,1,true]
allow_duplicates=[0,false,1,true]
list_id=[list_id]
drop_subscriptions=[list_id1,list_id2,list_idn]
header=[field1,field2,fieldn]

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

Powered by Zendesk