Create Contact
POST
https://api.mottasl.ai/v1/contact/create
Contactscreate
Last modified:2024-11-25 15:46:16
Request
Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.Example:
Authorization: Bearer ********************
Body Params application/json
mode
string
required
sync
mode, you can create up to 15 contacts per batch.In
async
mode, you can create up to 1000 contacts per batch.contacts
array[object (ContactObject) {8}]
required
mode
value.platform_id
string
required
platform_id
serves as the identifier for the specified platform type. For WhatsApp, it will correspond to the phone number.platform
string
required
whatsapp
is available for now.image_url
string
optional
profile_name
string
required
profile_display_name
string
required
profile_email
string
optional
country_code
string
required
tags
array[integer]
optional
Example
{
"mode": "string",
"contacts": [
{
"platform_id": "string",
"platform": "string",
"image_url": "string",
"profile_name": "string",
"profile_display_name": "string",
"profile_email": "string",
"country_code": "string",
"tags": [
0
]
}
]
}
Request samples
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.mottasl.ai/v1/contact/create' \
--header 'Content-Type: application/json' \
--data-raw '{
"mode": "string",
"contacts": [
{
"platform_id": "string",
"platform": "string",
"image_url": "string",
"profile_name": "string",
"profile_display_name": "string",
"profile_email": "string",
"country_code": "string",
"tags": [
0
]
}
]
}'
Responses
🟢200Success
application/json
Body
object {0}
Example
{}
🟠400BadRequest
Modified at 2024-11-25 15:46:16