AgentPublic
idemailfull_nameroleis_onlineConversationWithContact
idcontact_idstatuslast_message_atunread_countcreated_atupdated_atcontact_channelwhatsapp, instagram, or email
assigned_agent_idcontact_namecontact_phoneMessage
conversation_iddirectiontypecontentFree-form JSON. For text messages: {text: '...'}.
statuscreated_at_idMongoDB ObjectId hex string
external_idsender_phoneMessageListResponse
has_morenext_cursorMongoDB ObjectId hex for next page
SendMessageRequest
typecontentFree-form JSON. For text: {"text": "Hello"}. For image: {"url": "...", "caption": "..."}.
Contact
idchannel_sourcewhatsapp, instagram, or email
tagsJSON array of tag strings
created_atupdated_atphone_numbernameemailCreateAgent
emailMust contain @
passwordfull_nameroleDefaults to "agent" if omitted
UpdateAgent
emailAdmin only
full_nameroleAdmin only
passwordConversationNote
idconversation_idagent_idcontentcreated_atupdated_atNoteResponse
idconversation_idagent_idagent_namecontentcreated_atupdated_atQuickReply
idtitlecontentcreated_bycreated_atupdated_atshortcutcategoryCreateQuickReply
titlecontentshortcutcategoryOverviewResponse
total_conversationsopen_conversationspending_conversationsresolved_conversationstotal_contactstotal_agentsonline_agentsmessages_todayresolution_ratePercentage (0.0 - 100.0)
TrendsResponse
period7d, 30d, or 90d
daysAgentMetric
agent_idfull_nameemailis_onlineopen_conversationsresolved_conversationstotal_conversationsChannelMetric
channelcontact_countconversation_countMediaUploadResponse
media_idmime_typefile_sizefilenameDivision
idnamedescriptionallocation_methodis_activecreated_atupdated_atDivisionWithCount
idnamedescriptionallocation_methodis_activecreated_atupdated_atagent_countCreateDivision
namedescriptionallocation_methodUpdateDivision
namedescriptionallocation_methodis_activeTransferConversationRequest
to_agent_idto_division_idnoteConversationTransfer
idconversation_idtransferred_bycreated_atfrom_agent_idto_agent_idto_division_idnotefrom_agent_nameto_agent_nameto_division_nametransferred_by_nameScheduleMessageRequest
typecontentFree-form JSON message content
scheduled_atMust be in the future (UTC)
ScheduledMessage
idconversation_idscheduled_bymsg_typecontentscheduled_atstatuscreated_aterror_messagesent_atagent_nameCsatSurvey
idconversation_idcontact_idstatuscreated_atagent_idratingcommentrated_atagent_namecontact_nameSlaPolicy
idnamefirst_response_time_secsresolution_time_secswarning_threshold_pctpriorityis_activeis_defaultcreated_atupdated_atdescriptionchanneldivision_idCreateSlaPolicy
namedescriptionfirst_response_time_secsresolution_time_secswarning_threshold_pctprioritychanneldivision_idis_defaultUpdateSlaPolicy
namedescriptionfirst_response_time_secsresolution_time_secswarning_threshold_pctprioritychanneldivision_idis_activeis_defaultSlaBreachLog
idconversation_idsla_policy_idbreach_typethreshold_secsactual_secsbreached_atConversationSlaStatus
conversation_idpolicy_idpolicy_namefrt_statusfrt_elapsed_secsfrt_threshold_secsresolution_statusresolution_elapsed_secsresolution_threshold_secsIntegration
idchannelwhatsapp, instagram, email, or messenger
is_activeconfigChannel configuration (sensitive fields masked)
created_atupdated_atdivision_idIntegrationAccount
idchannelwhatsapp, instagram, email, or messenger
account_keyUnique key within a channel (e.g. wa-123456789)
display_nameis_activeis_defaultconfigAccount configuration (sensitive fields masked)
created_atupdated_atdivision_idverify_tokenwebhook_urlComputed webhook URL for this account
CreateIntegrationAccount
channelwhatsapp, instagram, email, or messenger
account_keyRequired for non-WhatsApp channels. Auto-derived from phone_number_id for WhatsApp.
display_nameis_activeis_defaultdivision_idconfigUpdateIntegrationAccount
account_keydisplay_nameis_activeis_defaultdivision_idconfigWaTemplate
idwaba_idWhatsApp Business Account ID
namelanguageBCP-47 language code (e.g. id, en_US)
categorystatuscomponentsMeta template components array (HEADER, BODY, FOOTER, BUTTONS)
created_atupdated_atmeta_template_idTemplate ID assigned by Meta
header_media_urlPublic MinIO URL for the header media (IMAGE/VIDEO/DOCUMENT)
CreateWaTemplate
nameLowercase letters, numbers, and underscores only. Max 512 chars.
componentsMeta template components array
languagecategoryintegration_account_idUse specific WABA account. Falls back to META_WABA_ID env var.
OutgoingWebhook
idnameurlsecreteventsJSON array of subscribed event type strings
is_activeconsecutive_failurescreated_atupdated_atcreated_bylast_triggered_atlast_success_atCreateOutgoingWebhook
nameurlMust start with http:// or https://
secreteventsValid types: message.received, message.sent, message.status, conversation.created, conversation.resolved, conversation.assigned, contact.created
WebhookDelivery
idwebhook_idevent_typepayloadstatusattemptmax_attemptscreated_athttp_statusresponse_bodyerror_messagenext_retry_atcompleted_atRole
idnamedescriptionis_systemRole bawaan sistem tidak dapat dihapus atau diubah namanya
created_atupdated_atRoleWithPermissions
idnamedescriptionis_systemRole bawaan sistem tidak dapat dihapus atau diubah namanya
created_atupdated_atpermissionsDaftar kode izin yang dimiliki role ini
Permission
idcodeKode izin dalam format category.action, misal: campaigns.manage
namedescriptioncategoryCreateRole
nameNama role (akan dinormalisasi ke huruf kecil). Tidak boleh sama dengan nama role sistem.
permissionsDaftar kode izin yang akan diberikan ke role ini
descriptionUpdateRole
nameTidak dapat diubah untuk role sistem
descriptionpermissionsMenggantikan seluruh daftar izin role (replace, bukan merge)
ApiKey
idagent_idnamekey_typekey_prefix12 karakter pertama dari plaintext key (bukan rahasia)
scopesJSON array of scope strings
is_activecreated_atlast_used_atexpires_atrevoked_atApiKeyCreateResponse
plaintext_keyPlaintext API key — hanya ditampilkan sekali saat pembuatan. Simpan dengan aman.
CreateApiKeyRequest
namekey_typeexpires_atTanggal kedaluwarsa opsional (UTC)
Campaign
idnametemplate_idstatustotal_recipientssent_countdelivered_countread_countfailed_countcreated_bycreated_atupdated_atscheduled_atintegration_account_idCampaignWithTemplate
idnametemplate_idstatustotal_recipientssent_countdelivered_countread_countfailed_countcreated_bycreated_atupdated_atscheduled_atintegration_account_idtemplate_nametemplate_languageCreateCampaign
nametemplate_idTemplate harus berstatus APPROVED
scheduled_atintegration_account_idUpdateCampaign
nametemplate_idscheduled_atintegration_account_idCampaignRecipient
idcampaign_idphone_numbervariablesVariabel template per penerima, misal: {"1": "John", "2": "Order #123"}
statuscreated_atcontact_idexternal_iderror_messagesent_atdelivered_atread_atconversation_idmongo_message_idAddRecipientsPayload
contact_idsTambahkan penerima berdasarkan ID kontak
tagsTambahkan semua kontak dengan tag yang cocok
phone_numbersTambahkan penerima langsung berdasarkan nomor telepon
variablesPemetaan variabel per nomor telepon: {"628xxx": {"1": "John", "2": "#123"}}
PaginatedResponse
totalpageper_pagetotal_pagesAutomationRule
idnamedescriptionis_activetrigger_typeConditions for rule matching (empty = always match)
Tagged-union array of automation actions
priorityrollout_percentagestop_on_matchcooldown_secscreated_atupdated_atsnoozed_untilcreated_byupdated_byCreateAutomationRule
nametrigger_typedescriptionis_activeconditionsalert_settingsschedule_settingspriorityrollout_percentagestop_on_matchcooldown_secsUpdateAutomationRule
namedescriptionis_activetrigger_typeconditionsalert_settingsschedule_settingspriorityrollout_percentagestop_on_matchcooldown_secsAutomationControl
singletonis_pausedupdated_atpause_reasonpaused_untilupdated_byAutomationRuleRun
idevent_idrule_idconversation_idmatchedexecutedresultcreated_atrule_nameAutomationEventQueueItem
idevent_typeconversation_idpayloadpayload_hashSHA-256 hex digest of the payload
sourcestatusattemptsavailable_atcreated_atcontact_idprocessed_aterrorChatExpirationRule
idchannelwindow_hoursHours before the messaging window closes (0 = never expires)
auto_resolveblock_text_after_windowis_activecreated_atupdated_atUpsertChatExpirationRule
window_hoursHours before window closes (0 = never expires)
auto_resolveblock_text_after_windowis_activeRegisterRequest
org_nameName of the new organization
admin_emailEmail for the initial admin user
admin_passwordPassword for the initial admin user (min 6 characters)
WorkingHours
idday_of_weekDay of the week (0 = Sunday, 6 = Saturday)
start_timeend_timeis_activecreated_atupdated_atdivision_idDaySchedule
day_of_weekstart_timeend_timeis_activeAiAgent
idnamesystem_promptmodeltemperaturemax_tokensis_activecreated_atupdated_atwelcome_messageparent_agent_iddaily_token_limitmax_conversation_turnsCreateAiAgent
namesystem_promptmodeltemperaturemax_tokenswelcome_messageparent_agent_iddaily_token_limitmax_conversation_turnsUpdateAiAgent
namesystem_promptmodeltemperaturemax_tokenswelcome_messageis_activeparent_agent_iddaily_token_limitmax_conversation_turnsAiAgentAssignment
idai_agent_idpriorityis_activechanneldivision_idCreateAiAgentAssignment
channeldivision_idpriorityUpdateAiAgentAssignment
channeldivision_idpriorityis_activeAiHandoffRule
idai_agent_idrule_typeconfigRule-specific configuration (e.g. keywords list, threshold)
stop_ai_after_handoffis_activetarget_division_idCreateAiHandoffRule
rule_typeconfigtarget_division_idstop_ai_after_handoffUpdateAiHandoffRule
rule_typeconfigtarget_division_idstop_ai_after_handoffis_activeAiKnowledgeSource
idai_agent_idnamesource_typechunk_countstatuscreated_atcontentfile_urloriginal_filenamewebsite_urlstatus_messageCreateAiKnowledgeSource
namesource_typecontentfile_urloriginal_filenamewebsite_urlAiKnowledgeQna
idknowledge_source_idquestionanswerAiProduct
idai_agent_idnamemetadataArbitrary JSON metadata for the product
is_activecreated_atdescriptionpriceProduct price as a decimal string
weightProduct weight as a decimal string
CreateAiProduct
namedescriptionpriceweightmetadataUpdateAiProduct
namedescriptionpriceweightmetadatais_activeAiOrchestrationRule
idparent_agent_idtarget_agent_idcondition_promptPrompt evaluated to decide whether to route to target agent
priorityis_activeCreateAiOrchestrationRule
target_agent_idcondition_promptpriorityUpdateAiOrchestrationRule
target_agent_idcondition_promptpriorityis_activeAiEvaluation
idconversation_idmessage_idMongoDB message ID
original_responsecorrected_responsecontext_message_idsIDs of messages used as evaluation context
evaluated_byAgent who performed the evaluation
created_atCreateAiEvaluation
conversation_idmessage_idoriginal_responsecorrected_responsecontext_message_idsAiUsageDailySummary
dateprompt_tokenscompletion_tokenstotal_tokenstotal_costEstimated cost in USD
request_countTestChatMessage
rolecontentOrganization
idnameslugstatusmongo_databaseschema_versioncreated_atupdated_atlimitsResource limits (max_agents, max_contacts, max_messages_month)
countryISO country code (e.g. ID, US)
CreateOrganization
nameslugURL-safe identifier for the tenant
limitscountryadmin_emailadmin_passwordTenantUsage
idorg_idagent_countcontact_countmessages_this_monthactive_integrationsusage_monthupdated_atTenantWithUsage
idnameslugstatusmongo_databaseschema_versioncreated_atupdated_atlimitsResource limits (max_agents, max_contacts, max_messages_month)
countryISO country code (e.g. ID, US)
SystemHealth
statusBillingPlan
idnameslugcurrencybase_price_monthlybase_price_annualper_agent_priceoverage_message_pricelimitsPlan resource limits (max_agents, max_contacts, max_messages_month, max_channels, max_ai_agents)
featuresFeature flags (ai_agent, api_access, dedicated_support)
is_activesort_ordercreated_atupdated_atCreateBillingPlan
nameslugbase_price_monthlyper_agent_priceoverage_message_pricelimitsfeaturescurrencybase_price_annualsort_orderUpdateBillingPlan
nameslugcurrencybase_price_monthlybase_price_annualper_agent_priceoverage_message_pricelimitsfeaturesis_activesort_orderBillingCoupon
idcodediscount_typediscount_valuecurrencycurrent_usesvalid_fromis_activecreated_atmax_usesvalid_untilapplicable_plansCreateBillingCoupon
codediscount_typediscount_valuecurrencymax_usesvalid_fromvalid_untilapplicable_plansBillingAddon
idnameslugprice_monthlyprice_annualunitPricing unit (e.g. flat, per agent)
is_activesort_ordercreated_atupdated_atdescriptionCreateBillingAddon
nameslugprice_monthlydescriptionprice_annualunitsort_orderUpdateBillingAddon
namedescriptionprice_monthlyprice_annualis_activesort_orderSubscription
idorg_idplan_idstatusbilling_periodcancel_at_period_endcreated_atupdated_attrial_ends_atcurrent_period_startcurrent_period_endpayment_gatewaygateway_customer_idgateway_subscription_idCurrentPlan
idorg_idplan_idstatusbilling_periodcancel_at_period_endcreated_atupdated_atplan_namelimitsfeaturestrial_ends_atcurrent_period_startcurrent_period_endpayment_gatewaygateway_customer_idgateway_subscription_idBillingInvoice
idorg_idinvoice_numbercurrencysubtotaltaxtotalstatusretry_countcreated_atsubscription_idpdf_urlgateway_invoice_idpayment_urllast_retry_atpaid_atdue_dateBillingUsage
org_idagent_countcontact_countmessages_this_monthactive_integrationsusage_monthlimitsPlan limits for comparison
PaymentMethod
idorg_idgatewaygateway_payment_method_idtypePayment method type (e.g. credit_card, e_wallet, virtual_account, bank_transfer)
labelis_defaultcreated_atAddPaymentMethod
gatewaygateway_payment_method_idtypePayment method type (e.g. credit_card, e_wallet, virtual_account)
labelis_defaultSubscriptionAddon
idsubscription_idaddon_idquantitycreated_atSubscriptionAddonDetail
idaddon_idnameslugprice_monthlyquantitycreated_atMrrSummary
total_mrrTotal monthly recurring revenue
active_subscriptionstrial_subscriptionspast_due_subscriptionscurrencyRevenueByPlan
plan_idplan_namesubscriber_countmonthly_revenuecurrencyMonthlyRevenue
monthtotal_revenueinvoice_countpaid_count