Reference · Tools

Mocean

Send SMS and voice messages via the MoceanAPI communications platform.

Action Communication v1

The Mocean node sends SMS messages and places text-to-speech voice calls through MoceanAPI. A typical build is escalating an unacknowledged alert from a text message to an automated phone call after a few minutes of silence.

Node type
Action
Parameters
8
Outputs
Output, Error
Credentials
Mocean API

Mocean

Send SMS and voice messages via MoceanAPI.

Overview

Mocean (MoceanAPI) is a cloud communications platform that provides SMS and voice call APIs. This tool sends SMS text messages via the /rest/2/sms endpoint and initiates text-to-speech voice calls via the /rest/2/voice/dial endpoint. Authentication uses API key and secret passed in the request body as form-encoded fields. Voice calls use a JSON command array to specify text-to-speech parameters including language.

Category: Communication
Tool Name: mocean
Version: 1

Appearance: Icon: lucide-MessageSquare | Color: #76C5D6

Node Type

Action — processes input items and produces output

Input / Output

DirectionPort(s)
InputInput
OutputOutput, Error

Credentials

This tool requires Mocean API credentials. See the Credentials Guide for setup instructions.

Resources

ResourceValue
SMSsms
Voicevoice

Operations

OperationValueDescription
SendsendSend an SMS or voice message

Parameters

SMS: Send

ParameterTypeRequiredDefaultDescription
FromstringYesThe sender phone number or sender ID. Supports expressions like {{ $json.sender }}.
TostringYesThe recipient phone number. Supports expressions like {{ $json.phone }}.
MessagestringYesThe message to send (text for SMS, or text to speak for voice calls). Supports expressions like {{ $json.body }}.
OptionscollectionNo{}Additional SMS settings.
— Delivery Report URLstringNoA URL to receive delivery report callbacks from Mocean. When provided, delivery report mask is automatically enabled. Supports expressions.

Voice: Send

ParameterTypeRequiredDefaultDescription
FromstringYesThe sender phone number or sender ID. Supports expressions like {{ $json.sender }}.
TostringYesThe recipient phone number. Supports expressions like {{ $json.phone }}.
LanguageoptionsNoen-USThe language for the text-to-speech voice message. Supports expressions.
Options: cmn-CN (Chinese Mandarin, China), en-GB (English, United Kingdom), en-US (English, United States), ja-JP (Japanese, Japan), ko-KR (Korean, Korea)
MessagestringYesThe message to send (text for SMS, or text to speak for voice calls). Supports expressions like {{ $json.body }}.

All Operations

ParameterTypeRequiredDefaultDescription
Max ConcurrencynumberNo10Maximum number of items to process concurrently.

Output Data

One output item per input item — neither operation fans out. The MoceanAPI result is merged into the item JSON at the top level, so the fields the item already carried pass through unchanged and binary data is forwarded.

Both operations add a type field naming which channel was used:

OperationMerged onto the item
SMS: SendThe entry from the API’s messages array (status and per-message metadata as Mocean returns it), plus type: "sms"
Voice: SendThe entry from the API’s voice array (call status and metadata as Mocean returns it), plus type: "voice"

If a request returns more than one result entry, the entries are combined into a single object before being merged onto the item. If the response contains no entries at all, the whole API response body is merged instead.

Reference the result downstream by expression, e.g. {{ $json.type }}.

Usage Examples

  • Send an SMS notification to a customer phone number
  • Make an automated voice call with a text-to-speech message
  • Send bulk SMS messages to a list of phone numbers
  • Send a voice call in Japanese to a Japanese phone number

Example Configuration

SMS message with a delivery report callback:

{
  "type": "mocean",
  "parameters": {
    "resource": "sms",
    "operation": "send",
    "from": "+1234567890",
    "to": "+0987654321",
    "message": "Hello! This is a test SMS message.",
    "options": {
      "dlrUrl": "https://your-webhook-url.com/delivery-report"
    }
  }
}

SMS message, minimal configuration:

{
  "type": "mocean",
  "parameters": {
    "resource": "sms",
    "operation": "send",
    "from": "YourBrand",
    "to": "+1234567890",
    "message": "Your verification code is 123456"
  }
}

Text-to-speech voice call:

{
  "type": "mocean",
  "parameters": {
    "resource": "voice",
    "operation": "send",
    "from": "+1234567890",
    "to": "+0987654321",
    "message": "Hello, this message will be spoken to you in English.",
    "language": "en-US"
  }
}

Voice call in a different language:

{
  "type": "mocean",
  "parameters": {
    "resource": "voice",
    "operation": "send",
    "from": "+1234567890",
    "to": "+81234567890",
    "message": "こんにちは、これは日本語の音声メッセージです。",
    "language": "ja-JP"
  }
}

SMS notification with delivery tracking, driven by the incoming item:

{
  "type": "mocean",
  "parameters": {
    "resource": "sms",
    "operation": "send",
    "from": "AlertSystem",
    "to": "{{ $json.customerPhone }}",
    "message": "Your order #{{ $json.orderId }} has been shipped and will arrive tomorrow.",
    "options": {
      "dlrUrl": "https://api.mycompany.com/webhooks/sms-delivery"
    }
  }
}

Automated voice call for verification:

{
  "type": "mocean",
  "parameters": {
    "resource": "voice",
    "operation": "send",
    "from": "+18005550100",
    "to": "+1234567890",
    "message": "Your verification code is 8 7 4 2 1 9. Please enter this code to complete your registration.",
    "language": "en-US"
  }
}

Multilingual voice support:

{
  "type": "mocean",
  "parameters": {
    "resource": "voice",
    "operation": "send",
    "from": "+1234567890",
    "to": "+8612345678900",
    "message": "您的验证码是123456,请在5分钟内输入。",
    "language": "cmn-CN"
  }
}

High-volume SMS campaign with concurrency held down:

{
  "type": "mocean",
  "parameters": {
    "resource": "sms",
    "operation": "send",
    "from": "Promotions",
    "to": "{{ $json.phone }}",
    "message": "Flash sale! 50% off everything. Use code FLASH50. Valid until midnight.",
    "maxConcurrency": 5
  }
}

Error Handling

ModeBehavior
stopHalts workflow on first error
continueSkips failed items, passes successful ones through
errorPortRoutes failed items to Error output port

Tips

Mocean sends SMS text messages and makes text-to-speech voice calls via the MoceanAPI platform. Use it to send notifications, alerts, or automated voice calls to phone numbers.

Key Notes

  • Options is a flat object. Add dlrUrl directly inside options — it is not an array and it is not nested under a further key.
  • Language is voice-only. It is not shown for SMS, and when you leave it alone a voice call is spoken in en-US.
  • Include country codes on both from and to for reliable delivery.
  • Max Concurrency helps you stay inside MoceanAPI rate limits when a single node processes many items.

Frequently asked questions

Where does the delivery-receipt URL go?

Add `dlrUrl` directly inside the flat Options object — it is not an array and is not nested under a further key.

Why is the Language setting not appearing?

Language is voice-only and is not shown for SMS. Left alone, a voice call is spoken in `en-US`.

Why are my messages not being delivered?

Include country codes on both the from and to numbers. Missing country codes are the most common cause of unreliable delivery.

Which credential does it need?

A Mocean API credential covering both the SMS and voice operations.

Build with the Mocean node

Drop it into a workflow, wire it to an agent, or call it on a schedule. You'll need Mocean API credentials first.

Open BusyBot

Last updated . Spotted something wrong? Tell us.