TypeScript
import { PeriskopeApi } from '@periskope/periskope-client';
const client = new PeriskopeApi({
authToken: 'YOUR_API_KEY',
phone: '919876543210', // the phone to act with (x-phone)
});
async function main() {
const response = await client.phones.resetPhone();
console.log(response);
}
main();curl -X POST 'https://api.periskope.app/v1/phones/reset' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'x-phone: 919876543210'Phone APIs
Reset Phone
Logs out the WhatsApp session and resets the phone to the QR state — rescan via GET /phones/qr to reconnect.
TypeScript
import { PeriskopeApi } from '@periskope/periskope-client';
const client = new PeriskopeApi({
authToken: 'YOUR_API_KEY',
phone: '919876543210', // the phone to act with (x-phone)
});
async function main() {
const response = await client.phones.resetPhone();
console.log(response);
}
main();curl -X POST 'https://api.periskope.app/v1/phones/reset' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'x-phone: 919876543210'Authorizations
Headers
Response
Reset triggered — no content
Was this page helpful?