2chat connects to a Nagent workspace with an API key. Once it is connected, agents can call 5 2chat actions, such as "Create Contact", "Get API Usage Info" and "List Contacts". Nothing is enabled on connect: each action is allowed one at a time, and an action with side effects runs or waits for a person according to the agent's level.
Every operation an agent can call against 2chat, with input parameters and output schema.
_2CHAT_CREATE_CONTACTTool to create a new contact in your 2Chat account. Use after gathering and verifying first name and at least one contact detail (email, phone, or address).
Input parameters
Last name of the new contact
First name of the new contact
A list of contact detail entries; at least one entry is required
Publicly accessible URL of the contact's profile picture
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
_2CHAT_GET_API_USAGE_INFOTool to retrieve current API usage and account information. Use when you need to monitor your remaining quotas before sending more requests.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
_2CHAT_LIST_CONTACTSTool to list all contacts in your 2Chat account. Use when you need to retrieve your contact list after confirming your account connection.
Input parameters
Zero-indexed page number to retrieve.
Optional. Used to filter contacts by connected number UUID.
Number of results returned per page. Must be between 1 and 50.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
_2CHAT_LIST_WEBHOOKSList all configured webhook subscriptions for WhatsApp and phone call events. Use this when you need to audit, review, or retrieve UUIDs of your active webhook subscriptions. Returns details including webhook UUID, event type, channel UUID, callback URL, and creation timestamp.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
_2CHAT_TEST_API_KEYTool to validate your API key and retrieve account info. Use when confirming credentials before performing other operations.
Output
Data from the action execution
Error if any occurred during the execution of the action
Whether or not the action execution was successful or not
Agents can call 5 2chat actions on Nagent, including "Create Contact", "Get API Usage Info" and "List Contacts". Create Contact: Create a new contact in your 2Chat account. Each action is listed on this page with its input parameters and its output.
2chat connects with an API key, under your workspace's own connection. Nothing is enabled on connect: each action is allowed one at a time and can be scoped to the agents that need it.
Create Contact takes 2 required inputs: first_name and contact_detail. It also takes 2 optional inputs: last_name and profile_pic_url. It returns data, error and successful.