falaai-api 1.21.49 → 1.21.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +36 -38
- data/docs/RiskAuditRequest.md +1 -1
- data/docs/WhatsappApi.md +93 -0
- data/docs/WhatsappConversation.md +32 -0
- data/docs/WhatsappConversationsResponse.md +28 -0
- data/docs/WhatsappMeta.md +48 -0
- data/docs/WhatsappSpeaker.md +20 -0
- data/docs/WhatsappUsage.md +24 -0
- data/docs/index.html +32 -29
- data/docs/llms.txt +18 -0
- data/docs/robots.txt +4 -0
- data/docs/sitemap.xml +8 -0
- data/lib/falaai-api/api/analysis_api.rb +1 -1
- data/lib/falaai-api/api/email_alerts_api.rb +1 -1
- data/lib/falaai-api/api/health_api.rb +1 -1
- data/lib/falaai-api/api/speech_api.rb +1 -1
- data/lib/falaai-api/api/usage_api.rb +1 -1
- data/lib/falaai-api/api/version_api.rb +1 -1
- data/lib/falaai-api/api/webhooks_api.rb +1 -1
- data/lib/falaai-api/api/whatsapp_api.rb +129 -0
- data/lib/falaai-api/api_client.rb +1 -1
- data/lib/falaai-api/api_error.rb +1 -1
- data/lib/falaai-api/api_model_base.rb +1 -1
- data/lib/falaai-api/configuration.rb +1 -1
- data/lib/falaai-api/models/audio_event.rb +1 -1
- data/lib/falaai-api/models/audio_input_meta.rb +1 -1
- data/lib/falaai-api/models/create_email_alert_request.rb +1 -1
- data/lib/falaai-api/models/create_webhook_request.rb +1 -1
- data/lib/falaai-api/models/diagnostic_analysis_map.rb +1 -1
- data/lib/falaai-api/models/diagnostic_audio_event.rb +1 -1
- data/lib/falaai-api/models/diagnostic_categorical_analysis.rb +1 -1
- data/lib/falaai-api/models/diagnostic_participant.rb +1 -1
- data/lib/falaai-api/models/diagnostic_request.rb +1 -1
- data/lib/falaai-api/models/diagnostic_response.rb +1 -1
- data/lib/falaai-api/models/diagnostic_text_analysis.rb +1 -1
- data/lib/falaai-api/models/diagnostic_usage.rb +1 -1
- data/lib/falaai-api/models/email_alert_item.rb +1 -1
- data/lib/falaai-api/models/email_alert_list_response.rb +1 -1
- data/lib/falaai-api/models/email_alert_message_response.rb +1 -1
- data/lib/falaai-api/models/email_event.rb +1 -1
- data/lib/falaai-api/models/health_response.rb +1 -1
- data/lib/falaai-api/models/http_validation_error.rb +1 -1
- data/lib/falaai-api/models/location_inner.rb +1 -1
- data/lib/falaai-api/models/message_response.rb +1 -1
- data/lib/falaai-api/models/participant.rb +1 -1
- data/lib/falaai-api/models/participant_diagnostic.rb +1 -1
- data/lib/falaai-api/models/risk_audit_analysis_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_applied_action_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_audio_event_model_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_audit_decisions_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_conversation_scores_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_detection_item_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_detections_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_indexer_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_meta_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_participant_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_participants_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_request.rb +9 -18
- data/lib/falaai-api/models/risk_audit_scores_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_scoring_explanation_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_summary_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_timeline_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_usage_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_v2.rb +1 -1
- data/lib/falaai-api/models/risk_audit_v2_response.rb +1 -1
- data/lib/falaai-api/models/risk_audit_verdict_v2.rb +1 -1
- data/lib/falaai-api/models/transcription_response.rb +1 -1
- data/lib/falaai-api/models/transcription_usage.rb +1 -1
- data/lib/falaai-api/models/update_email_alert_request.rb +1 -1
- data/lib/falaai-api/models/update_webhook_request.rb +1 -1
- data/lib/falaai-api/models/usage_by_key_item.rb +1 -1
- data/lib/falaai-api/models/usage_log_item.rb +1 -1
- data/lib/falaai-api/models/usage_log_response.rb +1 -1
- data/lib/falaai-api/models/validation_error.rb +1 -1
- data/lib/falaai-api/models/version_response.rb +1 -1
- data/lib/falaai-api/models/webhook_event.rb +1 -1
- data/lib/falaai-api/models/webhook_item.rb +1 -1
- data/lib/falaai-api/models/webhook_list_response.rb +1 -1
- data/lib/falaai-api/models/whatsapp_conversation.rb +356 -0
- data/lib/falaai-api/models/whatsapp_conversations_response.rb +285 -0
- data/lib/falaai-api/models/whatsapp_meta.rb +570 -0
- data/lib/falaai-api/models/whatsapp_speaker.rb +192 -0
- data/lib/falaai-api/models/whatsapp_usage.rb +246 -0
- data/lib/falaai-api/version.rb +2 -2
- data/lib/falaai-api.rb +7 -1
- metadata +17 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d83d046b979cd6c1d09c21c3c76a82ea6b0d17131e1018b972a7fea0a3a50f3e
|
|
4
|
+
data.tar.gz: ba6256865b059b177181ce24f00cd857a2df99b0af69584fd8b4131b3a00d7df
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 74c598532ababe5e246b16f3e260886235f8b5e7f25df353b3d7cd2dc27ee392c90dbd8b1d0fac9ece144e7f04efa1209368c102c847e5008e476eecf1a8c8be
|
|
7
|
+
data.tar.gz: d3590c7c1c2e1e20bb4157f73125daae0c297dff4d44b985f3fcb7df100f4233a3672e9e200e2f68592fa61b0cf804c2099bfeb2f7b3fc815221bf738aea537a
|
data/README.md
CHANGED
|
@@ -28,23 +28,6 @@ Telegram voice -> your STT -> FalaAI Risk Audit
|
|
|
28
28
|
CRM conversation -> FalaAI Risk Audit
|
|
29
29
|
```
|
|
30
30
|
|
|
31
|
-
## Use the APIs the way you want
|
|
32
|
-
|
|
33
|
-
Every FalaAI API is **independent and optional** — chain any subset, in any combination.
|
|
34
|
-
|
|
35
|
-
```mermaid
|
|
36
|
-
flowchart LR
|
|
37
|
-
A["Audio"] -.->|optional| T["Transcribe"]
|
|
38
|
-
T --> X["Text / dialog"]
|
|
39
|
-
S["Your own STT / CRM / chat / existing transcript"] --> X
|
|
40
|
-
X -.->|optional| D["Diagnostic"]
|
|
41
|
-
X -.->|optional| R["Risk Audit"]
|
|
42
|
-
D --> O["Structured intelligence + auditable report"]
|
|
43
|
-
R --> O
|
|
44
|
-
```
|
|
45
|
-
|
|
46
|
-
> Skip **Transcribe** if you already have text. Call only **Diagnostic**, only **Risk Audit**, or both.
|
|
47
|
-
|
|
48
31
|
## Install
|
|
49
32
|
|
|
50
33
|
```bash
|
|
@@ -137,10 +120,37 @@ FalaAI API is an **AI conversation-intelligence API** for analyzing customer-ser
|
|
|
137
120
|
|
|
138
121
|
## Use cases
|
|
139
122
|
|
|
140
|
-
- **Contact center / Quality**
|
|
141
|
-
- **Compliance / Legal**
|
|
142
|
-
- **CX / Operations**
|
|
143
|
-
- **BI / Data**
|
|
123
|
+
- **Contact center / Quality** - audit 100% of conversations instead of a sample.
|
|
124
|
+
- **Compliance / Legal** - auditable evidence for audits and disputes.
|
|
125
|
+
- **CX / Operations** - risk score, sentiment and reason per conversation.
|
|
126
|
+
- **BI / Data** - typed JSON ready for your database or analytics stack.
|
|
127
|
+
|
|
128
|
+
## Why FalaAI
|
|
129
|
+
|
|
130
|
+
- **Audit 100%, not a sample** - every conversation gets a score, not a random QA sample.
|
|
131
|
+
- **Auditable by design** - a compliance risk score with detections/violations and an HTML report you can hand to an auditor.
|
|
132
|
+
- **Credits, not tokens** - you know exactly what each call costs (per second of audio, per character of text, per conversation). Monthly plans + non-expiring top-up packs.
|
|
133
|
+
- **Zero-storage** - audio/text/results are processed and discarded; only usage/audit records remain. TLS in transit + at rest, per-account isolation (multitenancy), LGPD (you are the controller; Action Tec is the processor).
|
|
134
|
+
- **3 native languages** (PT/EN/ES) · **start free** (no card).
|
|
135
|
+
- **B2B ready** - one Enterprise plan serves N clients, no per-user fee (ideal for ISVs).
|
|
136
|
+
|
|
137
|
+
## Integrations
|
|
138
|
+
|
|
139
|
+
FalaAI is **language-independent** - integrate at **any point** of your pipeline (capture, transcription, analysis or audit). Common ecosystems:
|
|
140
|
+
|
|
141
|
+
| Ecosystem | How |
|
|
142
|
+
|---|---|
|
|
143
|
+
| **PABX / telephony (3CX, Asterisk, Genesys)** | Send the recording to Transcribe, or the transcript to Diagnostic/Risk Audit. |
|
|
144
|
+
| **CRM / ERP (Odoo, Salesforce, SAP Service Cloud, HubSpot)** | Attach the structured JSON (summary, reason, sentiment, risk score) to the record. |
|
|
145
|
+
| **Contact center / QA (Zendesk, Twilio Flex, Take Blip)** | Batch-audit conversations and feed the score into your QA dashboard. |
|
|
146
|
+
| **Chatbots / messaging (WhatsApp, Telegram, Microsoft Teams)** | Extract conversations from an export and analyze them. |
|
|
147
|
+
| **BI / Data** | Typed JSON ready for your warehouse or analytics stack. |
|
|
148
|
+
|
|
149
|
+
> These are **integration examples**, not certified native integrations. Any platform can integrate through **REST / cURL** - the standard, language-independent path. Native ingestion connectors are on the roadmap.
|
|
150
|
+
|
|
151
|
+
## BYOT - Bring Your Own Transcription
|
|
152
|
+
|
|
153
|
+
Already have speech-to-text (Whisper, Deepgram, AssemblyAI, your own)? **Skip Transcription** and send the text straight to **Diagnostic** and/or **Risk Audit**. You only pay for what you use.
|
|
144
154
|
|
|
145
155
|
## SDK surface (Ruby)
|
|
146
156
|
|
|
@@ -151,15 +161,16 @@ FalaAI API is an **AI conversation-intelligence API** for analyzing customer-ser
|
|
|
151
161
|
| `HealthApi` | `FalaAI` | `health_check` |
|
|
152
162
|
| `SpeechApi` | `FalaAI` | `create_transcription_v1_audio_transcriptions_post_with_http_info(...)` |
|
|
153
163
|
| `AnalysisApi` | `FalaAI` | `create_diagnostic_v1_analyze_diagnostic_post_with_http_info(...)`, `create_risk_audit_v1_analyze_risk_audit_post_with_http_info(...)` |
|
|
164
|
+
| `WhatsappApi` | `FalaAI` | `extract_conversations_v1_whatsapp_extract_conversations_post_with_http_info(...)` |
|
|
154
165
|
| `UsageApi` / `WebhooksApi` / `EmailAlertsApi` / `VersionApi` | `FalaAI` | management |
|
|
155
|
-
| Models | `FalaAI` | `DiagnosticRequest`, `RiskAuditRequest`, `Participant`, `DiagnosticAudioEvent` |
|
|
166
|
+
| Models | `FalaAI` | `DiagnosticRequest`, `RiskAuditRequest`, `Participant`, `DiagnosticAudioEvent`, `WhatsappConversationsResponse` |
|
|
156
167
|
| `ApiError` | `FalaAI` | HTTP errors |
|
|
157
168
|
|
|
158
169
|
> Model IDs: `falaai-transcribe-1`, `falaai-diagnostic-1`, `falaai-risk-audit-1`.
|
|
159
170
|
|
|
160
171
|
## Examples
|
|
161
172
|
|
|
162
|
-
Runnable examples in [`examples/`](./examples): `health.rb`, `transcribe.rb`, `diagnose.rb`, `audit.rb`.
|
|
173
|
+
Runnable examples in [`examples/`](./examples): `health.rb`, `transcribe.rb`, `diagnose.rb`, `audit.rb`, `whatsapp.rb`.
|
|
163
174
|
|
|
164
175
|
## Authentication
|
|
165
176
|
|
|
@@ -180,19 +191,6 @@ rescue FalaAI::ApiError => e
|
|
|
180
191
|
end
|
|
181
192
|
```
|
|
182
193
|
|
|
183
|
-
## Where to integrate (this SDK)
|
|
184
|
-
|
|
185
|
-
FalaAI is language-independent; this package targets **Ruby** backends.
|
|
186
|
-
|
|
187
|
-
| Platform / environment (this SDK's language: **Ruby**) | Integration |
|
|
188
|
-
|---|---|
|
|
189
|
-
| **Ruby on Rails** apps | `falaai-api` (Ruby) |
|
|
190
|
-
| Ruby workers / Sidekiq jobs | `falaai-api` (Ruby) |
|
|
191
|
-
| Ruby data pipelines | `falaai-api` (Ruby) |
|
|
192
|
-
| Other stacks (3CX, Salesforce, Genesys...) | REST / cURL — [API reference](https://api01-falaai.action.tec.br/docs) (or the SDK for that backend's language) |
|
|
193
|
-
|
|
194
|
-
> These are **integration examples**, not certified native integrations. Any platform can integrate through **REST / cURL** — see the [API reference](https://api01-falaai.action.tec.br/docs). Authenticated calls use `Authorization: Bearer fai_<key>`.
|
|
195
|
-
|
|
196
194
|
## Production usage
|
|
197
195
|
|
|
198
196
|
- Store API keys in environment variables or a secret manager — never hard-code.
|
|
@@ -204,7 +202,7 @@ FalaAI is language-independent; this package targets **Ruby** backends.
|
|
|
204
202
|
| Requirement | Version |
|
|
205
203
|
|---|---|
|
|
206
204
|
| Ruby | 2.7+ |
|
|
207
|
-
| API | v1.21.
|
|
205
|
+
| API | v1.21.51 |
|
|
208
206
|
|
|
209
207
|
## Documentation
|
|
210
208
|
|
|
@@ -217,7 +215,7 @@ FalaAI is language-independent; this package targets **Ruby** backends.
|
|
|
217
215
|
|
|
218
216
|
## Versioning
|
|
219
217
|
|
|
220
|
-
Semantic versioning; the SDK version tracks the API version (`1.21.
|
|
218
|
+
Semantic versioning; the SDK version tracks the API version (`1.21.51`). See [CHANGELOG.md](CHANGELOG.md) and [Releases](https://github.com/ActionTecBr/falaai-api-ruby/releases).
|
|
221
219
|
|
|
222
220
|
## Security
|
|
223
221
|
|
data/docs/RiskAuditRequest.md
CHANGED
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
| **response_language** | **String** | Language for analysis results (labels, categories, levels, actions, HTML report). Can differ from 'language'. Accepted: pt-BR, en-US, es-ES. | |
|
|
14
14
|
| **call_direction** | **String** | Who originated the call. inbound=client called, outbound=company called. If omitted, LLM infers from context. | [optional] |
|
|
15
15
|
| **participants** | [**Array<Participant>**](Participant.md) | Explicit participant roles. If omitted, LLM infers from dialog (Lei 17). When provided, used as ground truth — no inference. | [optional] |
|
|
16
|
-
| **response_format** | **String** | Response format version.
|
|
16
|
+
| **response_format** | **String** | Response format version. Only 'v2' (structured EN-US blocks) is available today. | [optional][default to 'v2'] |
|
|
17
17
|
| **client_reference_id** | **String** | Optional client-supplied ID echoed verbatim in the response. Use to correlate/sync with your system. Accepted charset: [A-Za-z0-9._:-], max 128 chars. Not idempotency. | [optional] |
|
|
18
18
|
|
|
19
19
|
## Example
|
data/docs/WhatsappApi.md
ADDED
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# FalaAI::WhatsappApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://api01-falaai.action.tec.br*
|
|
4
|
+
|
|
5
|
+
| Method | HTTP request | Description |
|
|
6
|
+
| ------ | ------------ | ----------- |
|
|
7
|
+
| [**extract_conversations_v1_whatsapp_extract_conversations_post**](WhatsappApi.md#extract_conversations_v1_whatsapp_extract_conversations_post) | **POST** /v1/whatsapp/extractConversations | Extract and segment WhatsApp conversations from an export |
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
## extract_conversations_v1_whatsapp_extract_conversations_post
|
|
11
|
+
|
|
12
|
+
> <WhatsappConversationsResponse> extract_conversations_v1_whatsapp_extract_conversations_post(file, start, _end, timezone, date_format, opts)
|
|
13
|
+
|
|
14
|
+
Extract and segment WhatsApp conversations from an export
|
|
15
|
+
|
|
16
|
+
### Examples
|
|
17
|
+
|
|
18
|
+
```ruby
|
|
19
|
+
require 'time'
|
|
20
|
+
require 'falaai-api'
|
|
21
|
+
# setup authorization
|
|
22
|
+
FalaAI.configure do |config|
|
|
23
|
+
# Configure Bearer authorization (fai_xxx): ApiKeyAuth
|
|
24
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
api_instance = FalaAI::WhatsappApi.new
|
|
28
|
+
file = File.new('/path/to/some/file') # File |
|
|
29
|
+
start = 'start_example' # String |
|
|
30
|
+
_end = '_end_example' # String |
|
|
31
|
+
timezone = 'timezone_example' # String |
|
|
32
|
+
date_format = 'date_format_example' # String |
|
|
33
|
+
opts = {
|
|
34
|
+
gap_minutes: 8.14, # Float |
|
|
35
|
+
min_messages: 56, # Integer |
|
|
36
|
+
chars_per_minute: 8.14, # Float |
|
|
37
|
+
client_reference_id: 'client_reference_id_example' # String |
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
begin
|
|
41
|
+
# Extract and segment WhatsApp conversations from an export
|
|
42
|
+
result = api_instance.extract_conversations_v1_whatsapp_extract_conversations_post(file, start, _end, timezone, date_format, opts)
|
|
43
|
+
p result
|
|
44
|
+
rescue FalaAI::ApiError => e
|
|
45
|
+
puts "Error when calling WhatsappApi->extract_conversations_v1_whatsapp_extract_conversations_post: #{e}"
|
|
46
|
+
end
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
#### Using the extract_conversations_v1_whatsapp_extract_conversations_post_with_http_info variant
|
|
50
|
+
|
|
51
|
+
This returns an Array which contains the response data, status code and headers.
|
|
52
|
+
|
|
53
|
+
> <Array(<WhatsappConversationsResponse>, Integer, Hash)> extract_conversations_v1_whatsapp_extract_conversations_post_with_http_info(file, start, _end, timezone, date_format, opts)
|
|
54
|
+
|
|
55
|
+
```ruby
|
|
56
|
+
begin
|
|
57
|
+
# Extract and segment WhatsApp conversations from an export
|
|
58
|
+
data, status_code, headers = api_instance.extract_conversations_v1_whatsapp_extract_conversations_post_with_http_info(file, start, _end, timezone, date_format, opts)
|
|
59
|
+
p status_code # => 2xx
|
|
60
|
+
p headers # => { ... }
|
|
61
|
+
p data # => <WhatsappConversationsResponse>
|
|
62
|
+
rescue FalaAI::ApiError => e
|
|
63
|
+
puts "Error when calling WhatsappApi->extract_conversations_v1_whatsapp_extract_conversations_post_with_http_info: #{e}"
|
|
64
|
+
end
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
### Parameters
|
|
68
|
+
|
|
69
|
+
| Name | Type | Description | Notes |
|
|
70
|
+
| ---- | ---- | ----------- | ----- |
|
|
71
|
+
| **file** | **File** | | |
|
|
72
|
+
| **start** | **String** | | |
|
|
73
|
+
| **_end** | **String** | | |
|
|
74
|
+
| **timezone** | **String** | | |
|
|
75
|
+
| **date_format** | **String** | | |
|
|
76
|
+
| **gap_minutes** | **Float** | | [optional][default to 720] |
|
|
77
|
+
| **min_messages** | **Integer** | | [optional][default to 2] |
|
|
78
|
+
| **chars_per_minute** | **Float** | | [optional][default to 800] |
|
|
79
|
+
| **client_reference_id** | **String** | | [optional] |
|
|
80
|
+
|
|
81
|
+
### Return type
|
|
82
|
+
|
|
83
|
+
[**WhatsappConversationsResponse**](WhatsappConversationsResponse.md)
|
|
84
|
+
|
|
85
|
+
### Authorization
|
|
86
|
+
|
|
87
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
|
88
|
+
|
|
89
|
+
### HTTP request headers
|
|
90
|
+
|
|
91
|
+
- **Content-Type**: multipart/form-data
|
|
92
|
+
- **Accept**: application/json
|
|
93
|
+
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# FalaAI::WhatsappConversation
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **conversation_id** | **String** | Conversation identifier in the batch | |
|
|
8
|
+
| **first_at** | **String** | Real start (wall-clock, ISO) | |
|
|
9
|
+
| **last_at** | **String** | Real end (wall-clock, ISO) | |
|
|
10
|
+
| **duration_seconds** | **Float** | (last - first) + last turn duration | |
|
|
11
|
+
| **speakers** | [**Array<WhatsappSpeaker>**](WhatsappSpeaker.md) | Speakers of THIS conversation (dynamic) | |
|
|
12
|
+
| **dialog** | **String** | Lines 'Speaker N: [HH:MM:SS.mmm - HH:MM:SS.mmm] text' (real offset) | |
|
|
13
|
+
| **message_count** | **Integer** | Number of messages | |
|
|
14
|
+
| **characters** | **Integer** | Total characters of the conversation | |
|
|
15
|
+
|
|
16
|
+
## Example
|
|
17
|
+
|
|
18
|
+
```ruby
|
|
19
|
+
require 'falaai-api'
|
|
20
|
+
|
|
21
|
+
instance = FalaAI::WhatsappConversation.new(
|
|
22
|
+
conversation_id: null,
|
|
23
|
+
first_at: null,
|
|
24
|
+
last_at: null,
|
|
25
|
+
duration_seconds: null,
|
|
26
|
+
speakers: null,
|
|
27
|
+
dialog: null,
|
|
28
|
+
message_count: null,
|
|
29
|
+
characters: null
|
|
30
|
+
)
|
|
31
|
+
```
|
|
32
|
+
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# FalaAI::WhatsappConversationsResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **id** | **String** | Unique identifier. Prefix 'wc-' + UUID | |
|
|
8
|
+
| **object** | **String** | Object type. Always 'conversations' | |
|
|
9
|
+
| **usage** | [**WhatsappUsage**](WhatsappUsage.md) | Usage and processing information | |
|
|
10
|
+
| **conversations** | [**Array<WhatsappConversation>**](WhatsappConversation.md) | Segmented conversations | |
|
|
11
|
+
| **client_reference_id** | **String** | Client-supplied ID echoed verbatim (if provided) | [optional] |
|
|
12
|
+
| **meta** | [**WhatsappMeta**](WhatsappMeta.md) | Segmentation parameters and counts | |
|
|
13
|
+
|
|
14
|
+
## Example
|
|
15
|
+
|
|
16
|
+
```ruby
|
|
17
|
+
require 'falaai-api'
|
|
18
|
+
|
|
19
|
+
instance = FalaAI::WhatsappConversationsResponse.new(
|
|
20
|
+
id: null,
|
|
21
|
+
object: null,
|
|
22
|
+
usage: null,
|
|
23
|
+
conversations: null,
|
|
24
|
+
client_reference_id: null,
|
|
25
|
+
meta: null
|
|
26
|
+
)
|
|
27
|
+
```
|
|
28
|
+
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# FalaAI::WhatsappMeta
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **file** | **String** | Uploaded file name | |
|
|
8
|
+
| **chat_txt** | **String** | chat.txt entry name inside the export | |
|
|
9
|
+
| **format** | **String** | Detected format: Android | iOS | |
|
|
10
|
+
| **date_format** | **String** | Date order used | |
|
|
11
|
+
| **timezone** | **String** | Timezone informed | |
|
|
12
|
+
| **start** | **String** | Window start (ISO) | |
|
|
13
|
+
| **_end** | **String** | Window end (ISO) | |
|
|
14
|
+
| **gap_minutes** | **Float** | Gap used to split conversations | |
|
|
15
|
+
| **min_messages** | **Integer** | Minimum messages per conversation | |
|
|
16
|
+
| **chars_per_minute** | **Float** | Chars per minute used to estimate duration | |
|
|
17
|
+
| **turns** | **Integer** | Total parsed turns | |
|
|
18
|
+
| **system_lines** | **Integer** | System lines ignored | |
|
|
19
|
+
| **conversations_total** | **Integer** | Conversations before window filter | |
|
|
20
|
+
| **conversations_in_window** | **Integer** | Conversations overlapping the window | |
|
|
21
|
+
| **monologues_dropped** | **Integer** | Single-speaker conversations dropped | |
|
|
22
|
+
| **conversations_selected** | **Integer** | Final conversations returned | |
|
|
23
|
+
|
|
24
|
+
## Example
|
|
25
|
+
|
|
26
|
+
```ruby
|
|
27
|
+
require 'falaai-api'
|
|
28
|
+
|
|
29
|
+
instance = FalaAI::WhatsappMeta.new(
|
|
30
|
+
file: null,
|
|
31
|
+
chat_txt: null,
|
|
32
|
+
format: null,
|
|
33
|
+
date_format: null,
|
|
34
|
+
timezone: null,
|
|
35
|
+
start: null,
|
|
36
|
+
_end: null,
|
|
37
|
+
gap_minutes: null,
|
|
38
|
+
min_messages: null,
|
|
39
|
+
chars_per_minute: null,
|
|
40
|
+
turns: null,
|
|
41
|
+
system_lines: null,
|
|
42
|
+
conversations_total: null,
|
|
43
|
+
conversations_in_window: null,
|
|
44
|
+
monologues_dropped: null,
|
|
45
|
+
conversations_selected: null
|
|
46
|
+
)
|
|
47
|
+
```
|
|
48
|
+
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# FalaAI::WhatsappSpeaker
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **label** | **String** | Speaker label (e.g. 'Speaker 1') | |
|
|
8
|
+
| **name** | **String** | Participant name from the export | |
|
|
9
|
+
|
|
10
|
+
## Example
|
|
11
|
+
|
|
12
|
+
```ruby
|
|
13
|
+
require 'falaai-api'
|
|
14
|
+
|
|
15
|
+
instance = FalaAI::WhatsappSpeaker.new(
|
|
16
|
+
label: null,
|
|
17
|
+
name: null
|
|
18
|
+
)
|
|
19
|
+
```
|
|
20
|
+
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# FalaAI::WhatsappUsage
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **conversations** | **Integer** | Number of conversations returned | |
|
|
8
|
+
| **characters** | **Integer** | Total characters across conversations | |
|
|
9
|
+
| **credits_consumed** | **Integer** | Credits consumed (1 per conversation) | |
|
|
10
|
+
| **processing_ms** | **Integer** | Total processing time in milliseconds | |
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```ruby
|
|
15
|
+
require 'falaai-api'
|
|
16
|
+
|
|
17
|
+
instance = FalaAI::WhatsappUsage.new(
|
|
18
|
+
conversations: null,
|
|
19
|
+
characters: null,
|
|
20
|
+
credits_consumed: null,
|
|
21
|
+
processing_ms: null
|
|
22
|
+
)
|
|
23
|
+
```
|
|
24
|
+
|