CRM
Create deal
POST
/
v1
/
crm
/
deals
Create deal
curl --request POST \
--url https://api.wazapin.com/v1/crm/deals \
--header 'Content-Type: application/json' \
--data '
{
"title": "<string>",
"amount": "<string>",
"company_ids": [
"<string>"
],
"contact_ids": [
"<string>"
],
"currency": "<string>",
"custom_fields": "<unknown>",
"expected_close_at": "<string>",
"metadata": "<unknown>",
"owner_user_id": "<string>",
"source_conversation_id": "<string>",
"stage_id": "<string>",
"status": "<string>"
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
title: '<string>',
amount: '<string>',
company_ids: ['<string>'],
contact_ids: ['<string>'],
currency: '<string>',
custom_fields: '<unknown>',
expected_close_at: '<string>',
metadata: '<unknown>',
owner_user_id: '<string>',
source_conversation_id: '<string>',
stage_id: '<string>',
status: '<string>'
})
};
fetch('https://api.wazapin.com/v1/crm/deals', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wazapin.com/v1/crm/deals"
payload = {
"title": "<string>",
"amount": "<string>",
"company_ids": ["<string>"],
"contact_ids": ["<string>"],
"currency": "<string>",
"custom_fields": "<unknown>",
"expected_close_at": "<string>",
"metadata": "<unknown>",
"owner_user_id": "<string>",
"source_conversation_id": "<string>",
"stage_id": "<string>",
"status": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"amount_in_home_currency": "<string>",
"amount_minor": "<string>",
"created_at": "<string>",
"currency_code": "<string>",
"custom_fields": "<unknown>",
"display_currency": "<string>",
"display_currency_minor": "<string>",
"display_currency_unit": 123,
"expected_close_at": "<string>",
"home_currency_at_write": "<string>",
"id": "<string>",
"metadata": "<unknown>",
"minor_unit": 123,
"owner_user_id": "<string>",
"source_conversation_id": "<string>",
"stage_id": "<string>",
"status": "<string>",
"title": "<string>",
"updated_at": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}Body
application/json
Response
OK
⌘I
Create deal
curl --request POST \
--url https://api.wazapin.com/v1/crm/deals \
--header 'Content-Type: application/json' \
--data '
{
"title": "<string>",
"amount": "<string>",
"company_ids": [
"<string>"
],
"contact_ids": [
"<string>"
],
"currency": "<string>",
"custom_fields": "<unknown>",
"expected_close_at": "<string>",
"metadata": "<unknown>",
"owner_user_id": "<string>",
"source_conversation_id": "<string>",
"stage_id": "<string>",
"status": "<string>"
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
title: '<string>',
amount: '<string>',
company_ids: ['<string>'],
contact_ids: ['<string>'],
currency: '<string>',
custom_fields: '<unknown>',
expected_close_at: '<string>',
metadata: '<unknown>',
owner_user_id: '<string>',
source_conversation_id: '<string>',
stage_id: '<string>',
status: '<string>'
})
};
fetch('https://api.wazapin.com/v1/crm/deals', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wazapin.com/v1/crm/deals"
payload = {
"title": "<string>",
"amount": "<string>",
"company_ids": ["<string>"],
"contact_ids": ["<string>"],
"currency": "<string>",
"custom_fields": "<unknown>",
"expected_close_at": "<string>",
"metadata": "<unknown>",
"owner_user_id": "<string>",
"source_conversation_id": "<string>",
"stage_id": "<string>",
"status": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"amount_in_home_currency": "<string>",
"amount_minor": "<string>",
"created_at": "<string>",
"currency_code": "<string>",
"custom_fields": "<unknown>",
"display_currency": "<string>",
"display_currency_minor": "<string>",
"display_currency_unit": 123,
"expected_close_at": "<string>",
"home_currency_at_write": "<string>",
"id": "<string>",
"metadata": "<unknown>",
"minor_unit": 123,
"owner_user_id": "<string>",
"source_conversation_id": "<string>",
"stage_id": "<string>",
"status": "<string>",
"title": "<string>",
"updated_at": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}