tallyfy 1.0.0__py3-none-any.whl

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.

Potentially problematic release.


This version of tallyfy might be problematic. Click here for more details.

@@ -0,0 +1,680 @@
1
+ Metadata-Version: 2.4
2
+ Name: tallyfy
3
+ Version: 1.0.0
4
+ Summary: A comprehensive Python SDK for interacting with the Tallyfy API
5
+ Home-page: https://github.com/tallyfy/tallyfy-sdk
6
+ Author: Tallyfy
7
+ Author-email: Tallyfy <support@tallyfy.com>
8
+ Maintainer-email: Tallyfy <support@tallyfy.com>
9
+ License: MIT
10
+ Project-URL: Documentation, https://tallyfy.com/products/
11
+ Project-URL: Repository, https://github.com/tallyfy/tallyfy-sdk
12
+ Project-URL: Bug Tracker, https://github.com/tallyfy/tallyfy-sdk/issues
13
+ Project-URL: Changelog, https://github.com/tallyfy/tallyfy-sdk/blob/main/CHANGELOG.md
14
+ Keywords: tallyfy,api,sdk,workflow,automation,task,management
15
+ Classifier: Development Status :: 5 - Production/Stable
16
+ Classifier: Intended Audience :: Developers
17
+ Classifier: License :: OSI Approved :: MIT License
18
+ Classifier: Operating System :: OS Independent
19
+ Classifier: Programming Language :: Python :: 3
20
+ Classifier: Programming Language :: Python :: 3.7
21
+ Classifier: Programming Language :: Python :: 3.8
22
+ Classifier: Programming Language :: Python :: 3.9
23
+ Classifier: Programming Language :: Python :: 3.10
24
+ Classifier: Programming Language :: Python :: 3.11
25
+ Classifier: Programming Language :: Python :: 3.12
26
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
27
+ Classifier: Topic :: Office/Business :: Scheduling
28
+ Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
29
+ Requires-Python: >=3.7
30
+ Description-Content-Type: text/markdown
31
+ License-File: LICENSE
32
+ Requires-Dist: requests>=2.25.0
33
+ Requires-Dist: typing-extensions>=4.0.0; python_version < "3.8"
34
+ Provides-Extra: dev
35
+ Requires-Dist: pytest>=6.0.0; extra == "dev"
36
+ Requires-Dist: pytest-cov>=2.10.0; extra == "dev"
37
+ Requires-Dist: black>=21.0.0; extra == "dev"
38
+ Requires-Dist: flake8>=3.8.0; extra == "dev"
39
+ Requires-Dist: mypy>=0.800; extra == "dev"
40
+ Dynamic: author
41
+ Dynamic: home-page
42
+ Dynamic: license-file
43
+ Dynamic: requires-python
44
+
45
+ # Tallyfy SDK
46
+
47
+ A comprehensive Python SDK for interacting with the Tallyfy API. This SDK provides a clean, modular interface for managing users, tasks, templates, and form fields in your Tallyfy organization.
48
+
49
+ ## Table of Contents
50
+
51
+ - [Installation](#installation)
52
+ - [Quick Start](#quick-start)
53
+ - [Architecture](#architecture)
54
+ - [Core Features](#core-features)
55
+ - [API Reference](#api-reference)
56
+ - [Data Models](#data-models)
57
+ - [Error Handling](#error-handling)
58
+ - [Examples](#examples)
59
+ - [Advanced Usage](#advanced-usage)
60
+ - [Contributing](#contributing)
61
+
62
+ ## Installation
63
+
64
+ ```bash
65
+ pip install -r requirements.txt
66
+ ```
67
+
68
+ **Dependencies:**
69
+ - `requests` - HTTP client library
70
+ - `typing` - Type hints support (Python 3.5+)
71
+
72
+ ## Quick Start
73
+
74
+ ```python
75
+ from tallyfy import TallyfySDK
76
+
77
+ # Initialize the SDK
78
+ sdk = TallyfySDK(
79
+ api_key="your_api_key_here",
80
+ base_url="https://api.tallyfy.com" # Optional, defaults to Tallyfy API
81
+ )
82
+
83
+ # Get organization users
84
+ users = sdk.users.get_organization_users(org_id="your_org_id")
85
+
86
+ # Get current user's tasks
87
+ my_tasks = sdk.tasks.get_my_tasks(org_id="your_org_id")
88
+
89
+ # Search for templates
90
+ templates = sdk.search(org_id="your_org_id", search_query="onboarding", search_type="blueprint")
91
+
92
+ # Get a specific template
93
+ template = sdk.templates.get_template(org_id="your_org_id", template_name="Employee Onboarding")
94
+ ```
95
+
96
+ ## Architecture
97
+
98
+ The Tallyfy SDK follows a modular architecture with specialized management classes and comprehensive data models:
99
+
100
+ ### Core Components
101
+
102
+ - **`TallyfySDK`** - Main SDK class that orchestrates all operations with backward compatibility methods
103
+ - **`BaseSDK`** - Base class with HTTP request handling, retry logic, and connection pooling
104
+ - **Management Modules:**
105
+ - `UserManagement` - User and guest operations with full profile support
106
+ - `TaskManagement` - Task and process operations with natural language processing
107
+ - `TemplateManagement` - Template/checklist operations with automation analysis
108
+ - `FormFieldManagement` - Form field operations with AI-powered suggestions
109
+ - **Utility Modules:**
110
+ - `DateExtractor` - Natural language date parsing and task extraction
111
+ - `TallyfyError` - Custom exception handling with status codes and response data
112
+
113
+ ### File Structure
114
+
115
+ ```
116
+ tallyfy/
117
+ ├── __init__.py # SDK exports and version
118
+ ├── core.py # BaseSDK and TallyfySDK classes
119
+ ├── models.py # Data models and types
120
+ ├── user_management.py # User and guest management
121
+ ├── task_management.py # Task and process management
122
+ ├── template_management.py # Template management
123
+ ├── form_fields_management.py # Form field management
124
+ └── README.md # This documentation
125
+ ```
126
+
127
+ ## Core Features
128
+
129
+ ### 🔐 Authentication & Security
130
+ - Bearer token authentication with session management
131
+ - Configurable request timeouts and connection pooling
132
+ - Automatic retry logic for transient failures (5xx errors)
133
+ - No retry for client errors (4xx) to prevent API abuse
134
+ - Comprehensive error handling with detailed error information
135
+
136
+ ### 👥 User Management
137
+ - Get organization members with full profile data (country, timezone, job details)
138
+ - Get minimal user lists for performance-critical operations
139
+ - Manage guests and external users with guest-specific features
140
+ - Invite new users to organization with role assignment
141
+ - Support for user groups and permissions
142
+
143
+ ### ✅ Task Management
144
+ - Get tasks for specific users or processes with filtering
145
+ - Create standalone tasks with rich assignment options
146
+ - **Natural language task creation** with automatic date/time extraction
147
+ - Search processes by name with fuzzy matching
148
+ - Advanced filtering for organization runs (status, owners, tags, etc.)
149
+ - Universal search across processes, templates, and tasks
150
+
151
+ ### 📋 Template Management
152
+ - Get templates with full metadata and step details
153
+ - Search templates by name with exact and fuzzy matching
154
+ - Update template properties and metadata
155
+ - Duplicate templates with permission copying options
156
+ - **Automation management** - Create, update, and analyze conditional rules
157
+ - **Step dependency analysis** - Understand step visibility conditions
158
+ - **AI-powered deadline suggestions** for individual steps
159
+ - **Template health assessment** - Comprehensive analysis of template quality
160
+ - **Automation consolidation** - Optimize and merge redundant rules
161
+ - Add assignees and edit step descriptions
162
+ - Kickoff field management for template launch forms
163
+
164
+ ### 📝 Form Field Management
165
+ - Add form fields to template steps with comprehensive validation
166
+ - Support for text, dropdown, date, file upload, WYSIWYG editor fields
167
+ - Update field properties, validation rules, and positioning
168
+ - Move fields between steps with automatic reordering
169
+ - **AI-powered field suggestions** based on step analysis
170
+ - Manage dropdown options with bulk updates
171
+ - **Smart field recommendations** with confidence scoring
172
+ - Field dependency management and conditional logic
173
+
174
+ ### 🔍 Search & Discovery
175
+ - Universal search across processes, templates, and tasks
176
+ - Exact and fuzzy matching with relevance scoring
177
+ - Pagination support with configurable page sizes
178
+ - Rich search results with metadata and context
179
+ - **Natural language date extraction** from search queries
180
+ - Process and template name-based search with suggestions
181
+
182
+ ### 🤖 Natural Language Processing
183
+ - **Task creation from natural language** with automatic parsing
184
+ - **Date extraction** supporting various formats ("next Monday at 12PM", "tomorrow morning")
185
+ - **User/guest resolution** from names and emails
186
+ - **Smart task parsing** extracting titles, descriptions, and deadlines
187
+ - **Fuzzy matching** for user names and process titles
188
+
189
+ ## API Reference
190
+
191
+ ### SDK Initialization
192
+
193
+ ```python
194
+ TallyfySDK(
195
+ api_key: str,
196
+ base_url: str = "https://api.tallyfy.com",
197
+ timeout: int = 30,
198
+ max_retries: int = 3,
199
+ retry_delay: float = 1.0
200
+ )
201
+ ```
202
+
203
+ ### User Management
204
+
205
+ ```python
206
+ # Get all organization users
207
+ users = sdk.users.get_organization_users(org_id, with_groups=False)
208
+
209
+ # Get minimal user list
210
+ users_list = sdk.users.get_organization_users_list(org_id)
211
+
212
+ # Get organization guests
213
+ guests = sdk.users.get_organization_guests(org_id, with_stats=False)
214
+
215
+ # Invite user to organization
216
+ user = sdk.users.invite_user_to_organization(
217
+ org_id, email, first_name, last_name,
218
+ role="light", message=None
219
+ )
220
+ ```
221
+
222
+ ### Task Management
223
+
224
+ ```python
225
+ # Get current user's tasks
226
+ my_tasks = sdk.tasks.get_my_tasks(org_id)
227
+
228
+ # Get specific user's tasks
229
+ user_tasks = sdk.tasks.get_user_tasks(org_id, user_id)
230
+
231
+ # Get tasks for a process
232
+ process_tasks = sdk.tasks.get_tasks_for_process(org_id, process_id=None, process_name="My Process")
233
+
234
+ # Get organization processes with filtering
235
+ runs = sdk.tasks.get_organization_runs(
236
+ org_id,
237
+ status="active",
238
+ owners="123,456",
239
+ checklist_id="template_id"
240
+ )
241
+
242
+ # Create standalone task
243
+ task = sdk.tasks.create_task(
244
+ org_id, title="Review Document",
245
+ deadline="2024-12-31T23:59:59Z",
246
+ description="Please review the attached document"
247
+ )
248
+
249
+ # Create task from natural language (via MCP Server)
250
+ task_result = create_task_from_text(
251
+ org_id,
252
+ "Create a task called Review Document with description Review the quarterly report the deadline is next Monday at 12PM",
253
+ user_emails=["john@company.com"],
254
+ max_assignable=2
255
+ )
256
+
257
+ # Search processes, templates, or tasks
258
+ results = sdk.tasks.search(org_id, "onboarding", search_type="process")
259
+
260
+ # Search for specific entity types
261
+ templates = sdk.tasks.search(org_id, "employee onboarding", search_type="blueprint")
262
+ tasks = sdk.tasks.search(org_id, "review", search_type="task")
263
+ ```
264
+
265
+ ### Template Management
266
+
267
+ ```python
268
+ # Get template by ID or name
269
+ template = sdk.templates.get_template(org_id, template_id=None, template_name="Onboarding")
270
+
271
+ # Get template with full step details
272
+ template_data = sdk.templates.get_template_with_steps(org_id, template_id)
273
+
274
+ # Update template metadata
275
+ updated = sdk.templates.update_template_metadata(
276
+ org_id, template_id,
277
+ title="New Title",
278
+ summary="Updated summary",
279
+ guidance="New guidance text"
280
+ )
281
+
282
+ # Get template steps
283
+ steps = sdk.templates.get_template_steps(org_id, template_id)
284
+
285
+ # Analyze step dependencies
286
+ dependencies = sdk.templates.get_step_dependencies(org_id, template_id, step_id)
287
+
288
+ # Get deadline suggestions
289
+ deadline_suggestion = sdk.templates.suggest_step_deadline(org_id, template_id, step_id)
290
+
291
+ # Advanced template operations
292
+ duplicated = sdk.templates.duplicate_template(org_id, template_id, "New Template Name", copy_permissions=True)
293
+
294
+ # Automation management
295
+ automation_data = {
296
+ "automated_alias": "Auto-assign reviewer",
297
+ "conditions": [{"field_id": "department", "operator": "equals", "value": "Engineering"}],
298
+ "actions": [{"type": "assign_step", "step_id": "review_step", "assignee_type": "user", "assignee_id": "123"}]
299
+ }
300
+ automation = sdk.templates.create_automation_rule(org_id, template_id, automation_data)
301
+
302
+ # Analyze automation conflicts and redundancies
303
+ analysis = sdk.templates.analyze_template_automations(org_id, template_id)
304
+
305
+ # Get consolidation suggestions
306
+ suggestions = sdk.templates.suggest_automation_consolidation(org_id, template_id)
307
+
308
+ # Assess overall template health
309
+ health_report = sdk.templates.assess_template_health(org_id, template_id)
310
+
311
+ # Add kickoff fields
312
+ kickoff_data = {
313
+ "field_type": "text",
314
+ "label": "Project Name",
315
+ "required": True,
316
+ "validation_rules": {"min_length": 3}
317
+ }
318
+ kickoff_field = sdk.templates.add_kickoff_field(org_id, template_id, kickoff_data)
319
+
320
+ # Add assignees to step
321
+ assignees = {"users": [123, 456], "groups": ["managers"], "guests": ["contractor@company.com"]}
322
+ sdk.templates.add_assignees_to_step(org_id, template_id, step_id, assignees)
323
+
324
+ # Edit step description
325
+ sdk.templates.edit_description_on_step(org_id, template_id, step_id, "Updated step description with detailed instructions")
326
+
327
+ # Add new step to template
328
+ step_data = {
329
+ "title": "Quality Review",
330
+ "description": "Perform final quality check",
331
+ "position": 5,
332
+ "assignees": {"users": [789]}
333
+ }
334
+ new_step = sdk.templates.add_step_to_template(org_id, template_id, step_data)
335
+ ```
336
+
337
+ ### Form Field Management
338
+
339
+ ```python
340
+ # Add form field to step
341
+ field_data = {
342
+ "field_type": "text",
343
+ "label": "Customer Name",
344
+ "required": True,
345
+ "position": 1
346
+ }
347
+ field = sdk.form_fields.add_form_field_to_step(org_id, template_id, step_id, field_data)
348
+
349
+ # Update form field
350
+ updated_field = sdk.form_fields.update_form_field(
351
+ org_id, template_id, step_id, field_id,
352
+ label="Updated Label",
353
+ required=False
354
+ )
355
+
356
+ # Move field between steps
357
+ success = sdk.form_fields.move_form_field(
358
+ org_id, template_id, from_step, field_id, to_step, position=2
359
+ )
360
+
361
+ # Delete form field
362
+ success = sdk.form_fields.delete_form_field(org_id, template_id, step_id, field_id)
363
+
364
+ # Get dropdown options
365
+ options = sdk.form_fields.get_dropdown_options(org_id, template_id, step_id, field_id)
366
+
367
+ # Update dropdown options
368
+ success = sdk.form_fields.update_dropdown_options(
369
+ org_id, template_id, step_id, field_id,
370
+ ["Option 1", "Option 2", "Option 3"]
371
+ )
372
+
373
+ # Get AI-powered field suggestions
374
+ suggestions = sdk.form_fields.suggest_form_fields_for_step(org_id, template_id, step_id)
375
+ ```
376
+
377
+ ## Data Models
378
+
379
+ The SDK provides comprehensive dataclasses for type safety and easy data access:
380
+
381
+ ### Core Models
382
+
383
+ - **`User`** - Organization member with full profile data (country, timezone, job details)
384
+ - **`Guest`** - External user with limited access and guest-specific details
385
+ - **`GuestDetails`** - Extended guest information and statistics
386
+ - **`Task`** - Individual work item with owners, deadlines, and process linkage
387
+ - **`Run`** - Process instance (workflow execution) with progress tracking
388
+ - **`Template`** - Complete template/checklist definition with automation rules
389
+ - **`Step`** - Individual step within a template with conditions and assignments
390
+
391
+ ### Assignment and Ownership Models
392
+
393
+ - **`TaskOwners`** - Task assignment information supporting users, guests, and groups
394
+ - **`RunProgress`** - Process completion tracking with step-level progress
395
+ - **`Country`** - Geographic data for user profiles
396
+ - **`Folder`** - Organizational folder structure for templates and processes
397
+
398
+ ### Template and Automation Models
399
+
400
+ - **`Tag`** - Industry and topic classification tags
401
+ - **`PrerunField`** - Form fields for template kickoff with validation rules
402
+ - **`AutomationCondition`** - Conditional logic for workflow automation
403
+ - **`AutomationAction`** - Actions triggered by automation rules
404
+ - **`AutomatedAction`** - Complete automation rule with conditions and actions
405
+ - **`AutomationDeadline`** - Deadline configuration for automated actions
406
+ - **`AutomationAssignees`** - Assignee configuration for automated actions
407
+
408
+ ### Step and Form Models
409
+
410
+ - **`Capture`** - Form fields within steps with validation and positioning
411
+ - **`StepStartDate`** - Start date configuration for steps
412
+ - **`StepDeadline`** - Deadline configuration for individual steps
413
+ - **`StepBpToLaunch`** - Sub-process launch configuration
414
+
415
+ ### Search and Utility Models
416
+
417
+ - **`SearchResult`** - Unified search results for templates, processes, and tasks
418
+ - **`TallyfyError`** - Custom exception with status codes and response data
419
+
420
+ ### Model Features
421
+
422
+ - **Automatic parsing** from API responses via `from_dict()` class methods
423
+ - **Type safety** with comprehensive type hints
424
+ - **Nested object support** for complex data structures
425
+ - **Default value handling** for optional fields
426
+
427
+ Example model usage:
428
+
429
+ ```python
430
+ # Models automatically parse API responses
431
+ users = sdk.users.get_organization_users(org_id)
432
+ for user in users:
433
+ print(f"{user.full_name} ({user.email})")
434
+ if user.country:
435
+ print(f"Country: {user.country.name}")
436
+
437
+ # Access nested data safely
438
+ template = sdk.templates.get_template(org_id, template_name="Onboarding")
439
+ if template.automated_actions:
440
+ for automation in template.automated_actions:
441
+ print(f"Automation: {automation.automated_alias}")
442
+ for condition in automation.conditions:
443
+ print(f" Condition: {condition.statement}")
444
+ ```
445
+
446
+ ## Error Handling
447
+
448
+ The SDK provides comprehensive error handling through the `TallyfyError` class:
449
+
450
+ ```python
451
+ from tallyfy import TallyfyError
452
+
453
+ try:
454
+ users = sdk.users.get_organization_users("invalid_org_id")
455
+ except TallyfyError as e:
456
+ print(f"API Error: {e}")
457
+ print(f"Status Code: {e.status_code}")
458
+ print(f"Response Data: {e.response_data}")
459
+ except ValueError as e:
460
+ print(f"Validation Error: {e}")
461
+ ```
462
+
463
+ ### Error Types
464
+
465
+ - **`TallyfyError`** - API-specific errors with status codes and response data
466
+ - **`ValueError`** - Input validation errors for required parameters
467
+ - **`RequestException`** - Network and connection errors (automatically retried)
468
+
469
+ ### Retry Logic
470
+
471
+ The SDK automatically retries failed requests with configurable settings:
472
+
473
+ - **Server errors (5xx)** - Automatically retried up to `max_retries` times
474
+ - **Client errors (4xx)** - Not retried (indicates user/input error)
475
+ - **Network errors** - Retried with exponential backoff
476
+ - **Timeout errors** - Retried with configurable delay
477
+
478
+ ## Examples
479
+
480
+ ### Complete User Onboarding Workflow
481
+
482
+ ```python
483
+ from tallyfy import TallyfySDK, TaskOwners
484
+
485
+ sdk = TallyfySDK(api_key="your_api_key")
486
+ org_id = "your_org_id"
487
+
488
+ # 1. Invite new user
489
+ new_user = sdk.users.invite_user_to_organization(
490
+ org_id,
491
+ email="new.hire@company.com",
492
+ first_name="John",
493
+ last_name="Doe",
494
+ role="standard",
495
+ message="Welcome to the team! Please complete your onboarding."
496
+ )
497
+
498
+ # 2. Create onboarding task
499
+ if new_user:
500
+ owners = TaskOwners(users=[new_user.id])
501
+ onboarding_task = sdk.tasks.create_task(
502
+ org_id,
503
+ title="Complete Employee Onboarding",
504
+ deadline="2025-12-31 17:00:00",
505
+ description="Please complete all onboarding steps including HR paperwork and IT setup.",
506
+ owners=owners
507
+ )
508
+ print(f"Created onboarding task: {onboarding_task.id}")
509
+ ```
510
+
511
+ ### Template Analysis and Enhancement
512
+
513
+ ```python
514
+ # Get template with full details
515
+ template_data = sdk.templates.get_template_with_steps(org_id, template_name="Project Kickoff")
516
+
517
+ if template_data:
518
+ template = template_data['template']
519
+ print(f"Template: {template.title}")
520
+ print(f"Steps: {template_data['step_count']}")
521
+ print(f"Automations: {template_data['automation_count']}")
522
+
523
+ # Analyze each step for improvements
524
+ for step_data in template_data['steps']:
525
+ step_id = step_data['id']
526
+
527
+ # Get dependency analysis
528
+ dependencies = sdk.templates.get_step_dependencies(org_id, template.id, step_id)
529
+ if dependencies['has_conditional_visibility']:
530
+ print(f"Step '{step_data['title']}' has conditional logic")
531
+
532
+ # Get deadline suggestions
533
+ deadline_suggestion = sdk.templates.suggest_step_deadline(org_id, template.id, step_id)
534
+ print(f"Suggested deadline: {deadline_suggestion['suggested_deadline']}")
535
+
536
+ # Get form field suggestions
537
+ field_suggestions = sdk.form_fields.suggest_form_fields_for_step(org_id, template.id, step_id)
538
+ for suggestion in field_suggestions[:2]: # Top 2 suggestions
539
+ if suggestion['confidence'] > 0.7:
540
+ print(f"High-confidence field suggestion: {suggestion['field_config']['label']}")
541
+ ```
542
+
543
+ ### Advanced Process Management
544
+
545
+ ```python
546
+ # Get all active processes with comprehensive filtering
547
+ active_runs = sdk.tasks.get_organization_runs(
548
+ org_id,
549
+ status="active",
550
+ with_data="checklist,tasks,assets,tags",
551
+ form_fields_values=True,
552
+ starred=True
553
+ )
554
+
555
+ # Group by template
556
+ template_usage = {}
557
+ for run in active_runs:
558
+ template_id = run.checklist_id
559
+ if template_id not in template_usage:
560
+ template_usage[template_id] = {
561
+ 'template_name': run.checklist_title,
562
+ 'active_count': 0,
563
+ 'runs': []
564
+ }
565
+ template_usage[template_id]['active_count'] += 1
566
+ template_usage[template_id]['runs'].append(run)
567
+
568
+ # Show most used templates
569
+ sorted_templates = sorted(template_usage.items(), key=lambda x: x[1]['active_count'], reverse=True)
570
+ for template_id, data in sorted_templates[:5]:
571
+ print(f"{data['template_name']}: {data['active_count']} active processes")
572
+ ```
573
+
574
+ ## Advanced Usage
575
+
576
+ ### Custom Request Configuration
577
+
578
+ ```python
579
+ # SDK with custom configuration
580
+ sdk = TallyfySDK(
581
+ api_key="your_api_key",
582
+ base_url="https://api.tallyfy.com",
583
+ timeout=60, # 60 second timeout
584
+ max_retries=5, # Retry up to 5 times
585
+ retry_delay=2.0 # 2 second delay between retries
586
+ )
587
+ ```
588
+
589
+ ### Accessing Raw API Responses
590
+
591
+ ```python
592
+ # For advanced users who need raw API data
593
+ template_data = sdk.templates.get_template_with_steps(org_id, template_id)
594
+ raw_api_response = template_data['raw_data']
595
+
596
+ # Access nested API data not exposed in models
597
+ custom_fields = raw_api_response.get('custom_metadata', {})
598
+ ```
599
+
600
+ ### Batch Operations
601
+
602
+ ```python
603
+ # Efficiently process multiple operations
604
+ org_users = sdk.users.get_organization_users(org_id)
605
+ user_tasks = {}
606
+
607
+ for user in org_users[:10]: # Process first 10 users
608
+ try:
609
+ tasks = sdk.tasks.get_user_tasks(org_id, user.id)
610
+ user_tasks[user.id] = tasks
611
+ print(f"{user.full_name}: {len(tasks)} tasks")
612
+ except TallyfyError as e:
613
+ print(f"Failed to get tasks for {user.full_name}: {e}")
614
+ ```
615
+
616
+ ### Form Field Automation
617
+
618
+ ```python
619
+ # Automatically enhance templates with smart form fields
620
+ def enhance_template_with_smart_fields(org_id, template_id):
621
+ steps = sdk.templates.get_template_steps(org_id, template_id)
622
+
623
+ for step in steps:
624
+ # Get AI suggestions for each step
625
+ suggestions = sdk.form_fields.suggest_form_fields_for_step(org_id, template_id, step.id)
626
+
627
+ # Implement high-confidence suggestions
628
+ for suggestion in suggestions:
629
+ if suggestion['confidence'] > 0.8 and suggestion['priority'] == 'high':
630
+ field_data = suggestion['field_config']
631
+ try:
632
+ new_field = sdk.form_fields.add_form_field_to_step(
633
+ org_id, template_id, step.id, field_data
634
+ )
635
+ print(f"Added field '{field_data['label']}' to step '{step.title}'")
636
+ except TallyfyError as e:
637
+ print(f"Failed to add field: {e}")
638
+
639
+ # Use the enhancement function
640
+ enhance_template_with_smart_fields(org_id, "your_template_id")
641
+ ```
642
+
643
+ ## Contributing
644
+
645
+ ### Development Setup
646
+
647
+ 1. Clone the repository
648
+ 2. Install dependencies: `pip install -r requirements.txt`
649
+ 3. Set up environment variables in `.env`
650
+ 4. Run tests: `python -m pytest tests/`
651
+
652
+ ### Code Style
653
+
654
+ - Follow PEP 8 style guidelines
655
+ - Use type hints for all functions and methods
656
+ - Add comprehensive docstrings for public APIs
657
+ - Include error handling for all external API calls
658
+
659
+ ### Adding New Features
660
+
661
+ 1. Add methods to appropriate management class
662
+ 2. Create or update data models in `models.py`
663
+ 3. Add comprehensive docstrings and type hints
664
+ 4. Include error handling and logging
665
+ 5. Update this README with usage examples
666
+
667
+ ## License
668
+
669
+ This SDK is part of the Tallyfy MCP project. See the main project repository for license information.
670
+
671
+ ## Support
672
+
673
+ For bugs, feature requests, or questions:
674
+
675
+ 1. Check existing issues in the project repository
676
+ 2. Contact us at: support@tallyfy.com
677
+ ---
678
+
679
+ **Version:** 1.0.0
680
+ **Last Updated:** 2025
@@ -0,0 +1,13 @@
1
+ tallyfy/README.md,sha256=5K39EilNZNk5NTEw1Y-qYZlLqhw2rja_I_Hdd6boz90,21493
2
+ tallyfy/__init__.py,sha256=E4eHCzUwVOD9r3PQBXHdJv0KYPSNe-2lH7h1yKdUHQ8,492
3
+ tallyfy/core.py,sha256=f7T_1XL8hq2l7rv4bQSzJAg6xmgHnjWQxNgFoVnvxxg,16351
4
+ tallyfy/form_fields_management.py,sha256=-ifTFKQuA3pcftKfPAyNCV840DOJPqRvJPsBCDNXbWU,24223
5
+ tallyfy/models.py,sha256=zIcJdvzB0ms8j8KWIHoMxLPllVILIVH42US2csO9g6U,36240
6
+ tallyfy/task_management.py,sha256=DIfhbo8qU3DWzuLKBZtwPlFta_D6Ip9HH3PUltr3T2o,14785
7
+ tallyfy/template_management.py,sha256=Eg2zxcSorcXeSnhMltwu2McG0tt7omL9OUF7lzWK85k,120174
8
+ tallyfy/user_management.py,sha256=R7L8Nsszm7htvZDRou7C0zQvgFx0pbNmcjHHyWYbl3g,8581
9
+ tallyfy-1.0.0.dist-info/licenses/LICENSE,sha256=8HUsrXnc3l2sZxhPV9Z1gYinq76Q2Ym7ahYJy57QlLc,1063
10
+ tallyfy-1.0.0.dist-info/METADATA,sha256=kr3jHt4Js9WleXwvHOpTNMBYVgcYEIZRyxraXpI0ISI,23377
11
+ tallyfy-1.0.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
12
+ tallyfy-1.0.0.dist-info/top_level.txt,sha256=yIycWbR61EZJD0MYRPwUQjOS2XZw5B5jCWx1IP73KcM,8
13
+ tallyfy-1.0.0.dist-info/RECORD,,
@@ -0,0 +1,5 @@
1
+ Wheel-Version: 1.0
2
+ Generator: setuptools (80.9.0)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+