UNPKG

@zenvia/sdk

Version:

This SDK for [Node.js](https://nodejs.org/) was created based on the [Zenvia](https://www.zenvia.com/) [API](https://zenvia.github.io/zenvia-openapi-spec/).

20 lines (16 loc) 442 B
/** * Example to get a subscription. * * Run: * ZENVIA_API_TOKEN=your-api-token node subscription-get.js */ // const { Client } = require('@zenvia/sdk'); const { Client } = require('../dist'); const client = new Client('GKkj0dSHDN60yLdkZzVyj4-osKlMQXQj-5d4'); client.getTemplate('eb5f5a45-c4f2-4086-8f41-6cc423d4fac8') .then(response => { console.log('Response:', response); }) .catch(error => { console.log('Error:', error); });