1.0.9 • Published 7 months ago
@periskope/periskope-client v1.0.9
Periskope API TypeScript Client
This is the official TypeScript API client for the Periskope REST API.
Installation
npm install periskope-clientUsage
An example of initializing the API client and sending a message:
import { PeriskopeApi } from 'periskope-client';
const client = new PeriskopeApi({
authToken: ' <Your token> ',
phone: ' <Your phone number> ',
});
const test = async () => {
try {
const data = await client.message.send({
chat_id: " < Receiver's chat ID > ",
message: 'Hello from Periskope',
});
} catch (e) {
console.log(e);
}
};
test();Documentation
For more detailed reference documentation, have a look at the API documentation with Node examples.
Feedback
Any feedback, such as bugs, questions, comments, etc. can be reported as Issues in this repository, and will be handled by us in Periskope.