Templates pushes - ActiveCampaign/postmark.js GitHub Wiki
For these API requests you will need to use a account API token. Once you obtain it, you will need to use account API client.
let postmark = require("postmark")
const accountToken = "xxxx-xxxxx-xxxx-xxxxx-xxxxxx"
let accountClient = new postmark.AccountClient(accountToken);
Push templates
accountClient.pushTemplates({SourceServerID:1, DestinationServerID:2, PerformChanges: false}).then((result:TemplatesPush) => {
console.log(result.TotalCount);
console.log(result.Templates[0].Action);
console.log(result.Templates[0].Alias);
console.log(result.Templates[0].Name);
console.log(result.Templates[0].TemplateId);
}).catch((error) => {
console.error(error);
});