What is a JID in WhatsApp?

Definition

A JID is the address WhatsApp uses internally for anyone or anything you can message. It looks like an email address: an identifier, an at sign, and a server part that says what kind of thing it is. A phone number ends in one server suffix, a group in another, a channel in a third.

In more depth

WhatsApp inherited its addressing scheme from XMPP, where every participant has a Jabber ID. A user is their phone number in international digits followed by the user server suffix, a group is a long numeric identifier followed by the group suffix, and a channel uses its own suffix again. The part before the at sign is opaque: it is not a database row you can look up and it is not always a phone number, which is why newer group and channel events may carry a linked identity instead. Two suffixes exist for ordinary users because the web and mobile stacks grew up separately, and different libraries normalise to different ones. Wapito hides most of this: outputs always use one canonical user suffix, and inputs accept several forms so you can pass whatever your data already holds. What you must not do is build a JID by hand from an integer, because a group identifier is longer than a 64-bit integer and languages that parse JSON numbers eagerly will quietly round it. Keep every JID a string, from your database column type through to your logs.

In the Wapito API

On the wire it is the field chat_id:

{
  "chat_id": "441234567890@s.whatsapp.net",
  "from": "441234567890"
}

On the official Cloud API

Meta's Cloud API never exposes a JID. It addresses people by a phone number id and returns a wa_id in webhooks, so JIDs are a concept you only meet when you work against the protocol directly.

Wapito is an independent product. It is not affiliated with, endorsed by, sponsored by or certified by WhatsApp or Meta Platforms, Inc. WhatsApp is a trademark of Meta Platforms, Inc.

Related terms

Related

Try it on your own number

Create a channel, link a WhatsApp number by QR or pairing code, and call the API in a couple of minutes. The Sandbox plan is free and needs no card.