Installation
Client SDK Installation
Install and initialise the browser client.
JavaScript
npm install pingerchips-jsESM only — add "type": "module" to package.json, or use .mjs.
import Pingerchips from 'pingerchips-js';
const client = new Pingerchips('YOUR_APP_KEY');
// endpoint defaults to wss://queue.pingerchips.com/socket (prod)
// and ws://localhost:4000/socket (dev)
const channel = await client.subscribe('my-channel');
channel.bind('my-event', (data) => {
console.log('Received:', data);
});The socket connects as soon as you construct Pingerchips.
Private and presence channels
Set authEndpoint to a route on your server that returns an auth token:
const client = new Pingerchips('YOUR_APP_KEY', {
authEndpoint: '/pingerchips/auth',
authInfo: { token: userSessionToken }, // sent to your endpoint as `auth_info`
});
const inbox = await client.subscribe('private-user-123');
inbox.bind('notification', (data) => console.log(data));The SDK POSTs { socket_id, channel_name, auth_info } to your endpoint; your
server signs with the App Secret and returns { auth }. See
Channel Types.
Python
The Python package (pingerchips) is agent-only today — it has no pub/sub
client. Use it for Chat agents; for pub/sub
from Python, call the HTTP trigger API
directly.
Next steps
- Client SDK Reference — full API
- Channel Types — public, private, presence