Sync mailtool changes to Ticketmatic

Content

Resource URL

https://apps.ticketmatic.com/api/1/{accountname}/subscribers/sync

Example

Request

 1use Ticketmatic\Endpoints\Subscribers;
 2
 3Subscribers::sync($client, array(
 4    array(
 5        "email" => "info@test.com",
 6        "firstname" => "John",
 7        "lastname" => "Johnson",
 8        "oldemail" => "info@test.com",
 9        "subscribed" => true,
10    ),
11));

Response

This operation does not return a response. The status can be checked by looking at the HTTP status code.

Request

 1import (
 2    "github.com/ticketmatic/tm-go/ticketmatic"
 3    "github.com/ticketmatic/tm-go/ticketmatic/subscribers"
 4)
 5
 6err := subscribers.Sync(client, []*ticketmatic.SubscriberSync{
 7    &ticketmatic.SubscriberSync{
 8        Email: "info@test.com",
 9        Firstname: "John",
10        Lastname: "Johnson",
11        Oldemail: "info@test.com",
12        Subscribed: true,
13    },
14})

Response

This operation does not return a response. The status can be checked by looking at the HTTP status code.

Request

 1POST /api/1/{accountname}/subscribers/sync HTTP/1.1
 2Content-Type: application/json
 3
 4[
 5    {
 6        "email": "info@test.com",
 7        "firstname": "John",
 8        "lastname": "Johnson",
 9        "oldemail": "info@test.com",
10        "subscribed": true
11    }
12]

Response

This operation does not return a response. The status can be checked by looking at the HTTP status code.

Request body fields

This call expects an array of objects in the request body.

FieldDescription
email
string 
(required)

Subscriber e-mail

Example value:"info@test.com"
firstname
string

Subscriber first name

Example value:"John"
lastname
string

Subscriber last name

Example value:"Johnson"
oldemail
string

Previous value of the email field, to indicate a changed e-mail address.

Used to find the correct contact. The normal email field will be used when this field is ommitted or empty.

Example value:"info@test.com"
subscribed
bool 
(required)

Whether or not the subscriber is still subscribed

Example value:true

Type reference: SubscriberSync[]