Actions8
- Order Actions
- Service Actions
- Country Actions
- Account Actions
Order → Buy Number
AI-generatedSummary
Purchases a real-SIM phone number from VirtualSMS for a given service code and country, by sending a POST to /api/v1/customer/purchase. Returns the API's order response, which includes the order UUID used by the Get Status and Cancel operations.
Inputs
- Service Code (required) — Short service code such as 'wa' (WhatsApp), 'tg' (Telegram) or 'aws' (7-Eleven). These are codes, not slugs. Use Service: List to find them. Sent as
servicein the request body. - Country (required) — ISO 2-letter country code (e.g. US, GB, DE, AR). Sent as
countryin the request body.
Output shape
One output item per input item. Its json is the raw response from the VirtualSMS purchase endpoint. If the API returns an array, each element becomes its own item.
The exact response fields are not defined in the node. Expect the order UUID, but check the API for the full shape. Authentication uses the virtualSmsApi credential, and the base URL defaults to https://virtualsms.io. With Continue On Fail enabled, a failed item outputs {error: message}. Otherwise the node throws. The node does not poll for the SMS. Use Get Status afterwards.
Examples
Example 1: Get a US WhatsApp verification number
Resource: Order; Operation: Buy Number; Service Code: wa; Country: US
Example 2: Buy numbers dynamically for each incoming item
Set Service Code to {{ $json.service }} and Country to {{ $json.country }}. The node runs once per input item.