@iblai/iblai-api 4.266.0-core → 4.267.0-core

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.
Files changed (47) hide show
  1. package/dist/index.cjs.js +681 -41
  2. package/dist/index.cjs.js.map +1 -1
  3. package/dist/index.esm.js +681 -42
  4. package/dist/index.esm.js.map +1 -1
  5. package/dist/index.umd.js +681 -41
  6. package/dist/index.umd.js.map +1 -1
  7. package/dist/types/index.d.ts +5 -0
  8. package/dist/types/models/Deal.d.ts +12 -0
  9. package/dist/types/models/Organization.d.ts +12 -0
  10. package/dist/types/models/PaginatedTagList.d.ts +7 -0
  11. package/dist/types/models/PatchedDeal.d.ts +12 -0
  12. package/dist/types/models/PatchedOrganization.d.ts +12 -0
  13. package/dist/types/models/PatchedPerson.d.ts +12 -0
  14. package/dist/types/models/PatchedTag.d.ts +30 -0
  15. package/dist/types/models/Person.d.ts +12 -0
  16. package/dist/types/models/Tag.d.ts +30 -0
  17. package/dist/types/models/_TagAttachRequest.d.ts +6 -0
  18. package/dist/types/services/ActivitiesService.d.ts +1 -1
  19. package/dist/types/services/CrmService.d.ts +185 -10
  20. package/dist/types/services/DealsService.d.ts +34 -2
  21. package/dist/types/services/LeadSourcesService.d.ts +1 -1
  22. package/dist/types/services/OrganizationsService.d.ts +28 -2
  23. package/dist/types/services/PersonsService.d.ts +28 -2
  24. package/dist/types/services/PipelinesService.d.ts +2 -2
  25. package/dist/types/services/TagsService.d.ts +96 -0
  26. package/package.json +1 -1
  27. package/sdk_schema.yml +1484 -239
  28. package/src/core/OpenAPI.ts +1 -1
  29. package/src/index.ts +5 -0
  30. package/src/models/Deal.ts +12 -0
  31. package/src/models/Organization.ts +12 -0
  32. package/src/models/PaginatedTagList.ts +12 -0
  33. package/src/models/PatchedDeal.ts +12 -0
  34. package/src/models/PatchedOrganization.ts +12 -0
  35. package/src/models/PatchedPerson.ts +12 -0
  36. package/src/models/PatchedTag.ts +35 -0
  37. package/src/models/Person.ts +12 -0
  38. package/src/models/Tag.ts +35 -0
  39. package/src/models/_TagAttachRequest.ts +11 -0
  40. package/src/services/ActivitiesService.ts +2 -2
  41. package/src/services/CrmService.ts +399 -14
  42. package/src/services/DealsService.ts +71 -2
  43. package/src/services/LeadSourcesService.ts +2 -2
  44. package/src/services/OrganizationsService.ts +65 -2
  45. package/src/services/PersonsService.ts +65 -2
  46. package/src/services/PipelinesService.ts +4 -4
  47. package/src/services/TagsService.ts +201 -0
@@ -1,3 +1,4 @@
1
+ import type { _TagAttachRequest } from '../models/_TagAttachRequest';
1
2
  import type { Activity } from '../models/Activity';
2
3
  import type { Deal } from '../models/Deal';
3
4
  import type { DealLostRequest } from '../models/DealLostRequest';
@@ -12,6 +13,7 @@ import type { PaginatedOrganizationList } from '../models/PaginatedOrganizationL
12
13
  import type { PaginatedPersonList } from '../models/PaginatedPersonList';
13
14
  import type { PaginatedPipelineList } from '../models/PaginatedPipelineList';
14
15
  import type { PaginatedPipelineStageList } from '../models/PaginatedPipelineStageList';
16
+ import type { PaginatedTagList } from '../models/PaginatedTagList';
15
17
  import type { PatchedActivity } from '../models/PatchedActivity';
16
18
  import type { PatchedDeal } from '../models/PatchedDeal';
17
19
  import type { PatchedLeadSource } from '../models/PatchedLeadSource';
@@ -19,6 +21,7 @@ import type { PatchedOrganization } from '../models/PatchedOrganization';
19
21
  import type { PatchedPerson } from '../models/PatchedPerson';
20
22
  import type { PatchedPipeline } from '../models/PatchedPipeline';
21
23
  import type { PatchedPipelineStage } from '../models/PatchedPipelineStage';
24
+ import type { PatchedTag } from '../models/PatchedTag';
22
25
  import type { Person } from '../models/Person';
23
26
  import type { PersonInviteRequest } from '../models/PersonInviteRequest';
24
27
  import type { PersonInviteResponse } from '../models/PersonInviteResponse';
@@ -27,6 +30,7 @@ import type { PersonMergeRequest } from '../models/PersonMergeRequest';
27
30
  import type { PersonMergeResponse } from '../models/PersonMergeResponse';
28
31
  import type { Pipeline } from '../models/Pipeline';
29
32
  import type { PipelineStage } from '../models/PipelineStage';
33
+ import type { Tag } from '../models/Tag';
30
34
  import type { CancelablePromise } from '../core/CancelablePromise';
31
35
  export declare class CrmService {
32
36
  /**
@@ -70,7 +74,7 @@ export declare class CrmService {
70
74
  * Create an activity
71
75
  * Creates an Activity. Either `deal` or `person` must be supplied; both must belong to your Platform.
72
76
  *
73
- * **Required permission:** `Ibl.CRM/Activities/write`.
77
+ * **Required permission:** `Ibl.CRM/Activities/action`.
74
78
  * @returns Activity
75
79
  * @throws ApiError
76
80
  */
@@ -157,7 +161,7 @@ export declare class CrmService {
157
161
  * @returns PaginatedDealList
158
162
  * @throws ApiError
159
163
  */
160
- static crmDealsList({ createdAtGte, createdAtLte, expectedCloseDateGte, expectedCloseDateLte, metadataHasKey, organization, owner, page, pageSize, person, pipeline, source, stage, status, }: {
164
+ static crmDealsList({ createdAtGte, createdAtLte, expectedCloseDateGte, expectedCloseDateLte, metadataHasKey, organization, owner, page, pageSize, person, pipeline, source, stage, status, tags, }: {
161
165
  createdAtGte?: string;
162
166
  createdAtLte?: string;
163
167
  expectedCloseDateGte?: string;
@@ -185,12 +189,13 @@ export declare class CrmService {
185
189
  * * `lost` - Lost
186
190
  */
187
191
  status?: 'lost' | 'open' | 'won';
192
+ tags?: string;
188
193
  }): CancelablePromise<PaginatedDealList>;
189
194
  /**
190
195
  * Create a deal
191
196
  * Creates a new Deal. All FK targets (`person`, `organization`, `pipeline`, `stage`, `source`) must belong to your Platform; `stage` must belong to `pipeline`. `status` and `closed_at` are service-managed — passing them returns `400`.
192
197
  *
193
- * **Required permission:** `Ibl.CRM/Deals/write`.
198
+ * **Required permission:** `Ibl.CRM/Deals/action`.
194
199
  * @returns Deal
195
200
  * @throws ApiError
196
201
  */
@@ -285,6 +290,36 @@ export declare class CrmService {
285
290
  id: number;
286
291
  requestBody?: DealMoveStageRequest;
287
292
  }): CancelablePromise<Deal>;
293
+ /**
294
+ * Attach a tag to this record
295
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
296
+ *
297
+ * **Required permission:** `Ibl.CRM/Tags/write`.
298
+ * @returns any No response body
299
+ * @throws ApiError
300
+ */
301
+ static crmDealsTagsCreate({ id, requestBody, }: {
302
+ /**
303
+ * A unique integer value identifying this deal.
304
+ */
305
+ id: number;
306
+ requestBody: _TagAttachRequest;
307
+ }): CancelablePromise<any>;
308
+ /**
309
+ * Detach a tag from this record
310
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
311
+ *
312
+ * **Required permission:** `Ibl.CRM/Tags/write`.
313
+ * @returns void
314
+ * @throws ApiError
315
+ */
316
+ static crmDealsTagsDestroy({ id, tagId, }: {
317
+ /**
318
+ * A unique integer value identifying this deal.
319
+ */
320
+ id: number;
321
+ tagId: string;
322
+ }): CancelablePromise<void>;
288
323
  /**
289
324
  * Mark a deal as won
290
325
  * Moves the Deal into a closed-won stage and sets `status='won'`. If `stage_code` is omitted, the first `is_won=True` stage in the Deal's pipeline (by sort order) is used.
@@ -324,7 +359,7 @@ export declare class CrmService {
324
359
  * Create a lead source
325
360
  * Creates a new LeadSource in your Platform. `code` must be unique.
326
361
  *
327
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
362
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
328
363
  * @returns LeadSource
329
364
  * @throws ApiError
330
365
  */
@@ -397,7 +432,7 @@ export declare class CrmService {
397
432
  * @returns PaginatedOrganizationList
398
433
  * @throws ApiError
399
434
  */
400
- static crmOrganizationsList({ name, owner, page, pageSize, }: {
435
+ static crmOrganizationsList({ name, owner, page, pageSize, tags, }: {
401
436
  name?: string;
402
437
  owner?: number;
403
438
  /**
@@ -408,12 +443,13 @@ export declare class CrmService {
408
443
  * Number of results to return per page.
409
444
  */
410
445
  pageSize?: number;
446
+ tags?: string;
411
447
  }): CancelablePromise<PaginatedOrganizationList>;
412
448
  /**
413
449
  * Create an organization
414
450
  * Creates a new organization in your Platform. The Platform is inferred from your credentials. `name` must be unique within your Platform.
415
451
  *
416
- * **Required permission:** `Ibl.CRM/Organizations/write`.
452
+ * **Required permission:** `Ibl.CRM/Organizations/action`.
417
453
  * @returns Organization
418
454
  * @throws ApiError
419
455
  */
@@ -466,6 +502,30 @@ export declare class CrmService {
466
502
  static crmOrganizationsDestroy({ id, }: {
467
503
  id: string;
468
504
  }): CancelablePromise<void>;
505
+ /**
506
+ * Attach a tag to this record
507
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
508
+ *
509
+ * **Required permission:** `Ibl.CRM/Tags/write`.
510
+ * @returns any No response body
511
+ * @throws ApiError
512
+ */
513
+ static crmOrganizationsTagsCreate({ id, requestBody, }: {
514
+ id: string;
515
+ requestBody: _TagAttachRequest;
516
+ }): CancelablePromise<any>;
517
+ /**
518
+ * Detach a tag from this record
519
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
520
+ *
521
+ * **Required permission:** `Ibl.CRM/Tags/write`.
522
+ * @returns void
523
+ * @throws ApiError
524
+ */
525
+ static crmOrganizationsTagsDestroy({ id, tagId, }: {
526
+ id: string;
527
+ tagId: string;
528
+ }): CancelablePromise<void>;
469
529
  /**
470
530
  * List persons
471
531
  * Returns a paginated list of persons in your Platform. Supports filtering by `lifecycle_stage`, `owner`, `organization`, `created_at__gte`/`created_at__lte`, and `metadata__has_key`.
@@ -474,7 +534,7 @@ export declare class CrmService {
474
534
  * @returns PaginatedPersonList
475
535
  * @throws ApiError
476
536
  */
477
- static crmPersonsList({ createdAtGte, createdAtLte, lifecycleStage, metadataHasKey, organization, owner, page, pageSize, }: {
537
+ static crmPersonsList({ createdAtGte, createdAtLte, lifecycleStage, metadataHasKey, organization, owner, page, pageSize, tags, }: {
478
538
  createdAtGte?: string;
479
539
  createdAtLte?: string;
480
540
  /**
@@ -498,12 +558,13 @@ export declare class CrmService {
498
558
  * Number of results to return per page.
499
559
  */
500
560
  pageSize?: number;
561
+ tags?: string;
501
562
  }): CancelablePromise<PaginatedPersonList>;
502
563
  /**
503
564
  * Create a person
504
565
  * Creates a new person in your Platform. The Platform is inferred from your credentials. If `organization` is supplied, it must reference an organization in your Platform.
505
566
  *
506
- * **Required permission:** `Ibl.CRM/Persons/write`.
567
+ * **Required permission:** `Ibl.CRM/Persons/action`.
507
568
  * @returns Person
508
569
  * @throws ApiError
509
570
  */
@@ -584,6 +645,30 @@ export declare class CrmService {
584
645
  id: string;
585
646
  requestBody: PersonLinkUserRequest;
586
647
  }): CancelablePromise<Person>;
648
+ /**
649
+ * Attach a tag to this record
650
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
651
+ *
652
+ * **Required permission:** `Ibl.CRM/Tags/write`.
653
+ * @returns any No response body
654
+ * @throws ApiError
655
+ */
656
+ static crmPersonsTagsCreate({ id, requestBody, }: {
657
+ id: string;
658
+ requestBody: _TagAttachRequest;
659
+ }): CancelablePromise<any>;
660
+ /**
661
+ * Detach a tag from this record
662
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
663
+ *
664
+ * **Required permission:** `Ibl.CRM/Tags/write`.
665
+ * @returns void
666
+ * @throws ApiError
667
+ */
668
+ static crmPersonsTagsDestroy({ id, tagId, }: {
669
+ id: string;
670
+ tagId: string;
671
+ }): CancelablePromise<void>;
587
672
  /**
588
673
  * Merge duplicate persons into a primary
589
674
  * Marks each person in `duplicate_ids` as inactive and reports how many related records (deals, activities, tags) were re-parented onto `primary_id`.
@@ -622,7 +707,7 @@ export declare class CrmService {
622
707
  * Create a pipeline
623
708
  * Creates a new Pipeline. `code` must be unique within your Platform. Promoting another Pipeline to `is_default=true` while one already exists will fail — unset the existing default first.
624
709
  *
625
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
710
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
626
711
  * @returns Pipeline
627
712
  * @throws ApiError
628
713
  */
@@ -655,7 +740,7 @@ export declare class CrmService {
655
740
  * Create a stage
656
741
  * Creates a new PipelineStage in the URL Pipeline. `code` must be unique within that Pipeline. At most one of `is_won` / `is_lost` may be true.
657
742
  *
658
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
743
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
659
744
  * @returns PipelineStage
660
745
  * @throws ApiError
661
746
  */
@@ -771,4 +856,94 @@ export declare class CrmService {
771
856
  */
772
857
  id: number;
773
858
  }): CancelablePromise<void>;
859
+ /**
860
+ * List tags
861
+ * Returns a paginated list of Tags in your Platform. Supports filtering by `name` (case-insensitive substring) and `created_at__gte`/`created_at__lte` ISO timestamp ranges.
862
+ *
863
+ * **Required permission:** `Ibl.CRM/Tags/list`.
864
+ * @returns PaginatedTagList
865
+ * @throws ApiError
866
+ */
867
+ static crmTagsList({ createdAtGte, createdAtLte, name, page, pageSize, }: {
868
+ createdAtGte?: string;
869
+ createdAtLte?: string;
870
+ name?: string;
871
+ /**
872
+ * A page number within the paginated result set.
873
+ */
874
+ page?: number;
875
+ /**
876
+ * Number of results to return per page.
877
+ */
878
+ pageSize?: number;
879
+ }): CancelablePromise<PaginatedTagList>;
880
+ /**
881
+ * Create a tag
882
+ * Creates a new Tag in your Platform. `name` must be unique within your Platform; supply `color` as a `#RRGGBB` hex string (defaults to `#888888`).
883
+ *
884
+ * **Required permission:** `Ibl.CRM/Tags/action`.
885
+ * @returns Tag
886
+ * @throws ApiError
887
+ */
888
+ static crmTagsCreate({ requestBody, }: {
889
+ requestBody: Tag;
890
+ }): CancelablePromise<Tag>;
891
+ /**
892
+ * Retrieve a tag
893
+ * Returns a single Tag by id.
894
+ *
895
+ * **Required permission:** `Ibl.CRM/Tags/read`.
896
+ * @returns Tag
897
+ * @throws ApiError
898
+ */
899
+ static crmTagsRetrieve({ id, }: {
900
+ /**
901
+ * A unique integer value identifying this tag.
902
+ */
903
+ id: number;
904
+ }): CancelablePromise<Tag>;
905
+ /**
906
+ * Replace a tag
907
+ * Replaces all editable fields on the Tag.
908
+ *
909
+ * **Required permission:** `Ibl.CRM/Tags/write`.
910
+ * @returns Tag
911
+ * @throws ApiError
912
+ */
913
+ static crmTagsUpdate({ id, requestBody, }: {
914
+ /**
915
+ * A unique integer value identifying this tag.
916
+ */
917
+ id: number;
918
+ requestBody: Tag;
919
+ }): CancelablePromise<Tag>;
920
+ /**
921
+ * Update a tag
922
+ * Updates only the supplied fields on the Tag (typically `name` or `color`).
923
+ *
924
+ * **Required permission:** `Ibl.CRM/Tags/write`.
925
+ * @returns Tag
926
+ * @throws ApiError
927
+ */
928
+ static crmTagsPartialUpdate({ id, requestBody, }: {
929
+ /**
930
+ * A unique integer value identifying this tag.
931
+ */
932
+ id: number;
933
+ requestBody?: PatchedTag;
934
+ }): CancelablePromise<Tag>;
935
+ /**
936
+ * Delete a tag
937
+ * Deletes the Tag. All attachments to Persons, Organizations, and Deals are removed atomically via cascade.
938
+ *
939
+ * **Required permission:** `Ibl.CRM/Tags/delete`.
940
+ * @returns void
941
+ * @throws ApiError
942
+ */
943
+ static crmTagsDestroy({ id, }: {
944
+ /**
945
+ * A unique integer value identifying this tag.
946
+ */
947
+ id: number;
948
+ }): CancelablePromise<void>;
774
949
  }
@@ -1,3 +1,4 @@
1
+ import type { _TagAttachRequest } from '../models/_TagAttachRequest';
1
2
  import type { Deal } from '../models/Deal';
2
3
  import type { DealLostRequest } from '../models/DealLostRequest';
3
4
  import type { DealMoveStageRequest } from '../models/DealMoveStageRequest';
@@ -14,7 +15,7 @@ export declare class DealsService {
14
15
  * @returns PaginatedDealList
15
16
  * @throws ApiError
16
17
  */
17
- static dealsList({ createdAtGte, createdAtLte, expectedCloseDateGte, expectedCloseDateLte, metadataHasKey, organization, owner, page, pageSize, person, pipeline, source, stage, status, }: {
18
+ static dealsList({ createdAtGte, createdAtLte, expectedCloseDateGte, expectedCloseDateLte, metadataHasKey, organization, owner, page, pageSize, person, pipeline, source, stage, status, tags, }: {
18
19
  createdAtGte?: string;
19
20
  createdAtLte?: string;
20
21
  expectedCloseDateGte?: string;
@@ -42,12 +43,13 @@ export declare class DealsService {
42
43
  * * `lost` - Lost
43
44
  */
44
45
  status?: 'lost' | 'open' | 'won';
46
+ tags?: string;
45
47
  }): CancelablePromise<PaginatedDealList>;
46
48
  /**
47
49
  * Create a deal
48
50
  * Creates a new Deal. All FK targets (`person`, `organization`, `pipeline`, `stage`, `source`) must belong to your Platform; `stage` must belong to `pipeline`. `status` and `closed_at` are service-managed — passing them returns `400`.
49
51
  *
50
- * **Required permission:** `Ibl.CRM/Deals/write`.
52
+ * **Required permission:** `Ibl.CRM/Deals/action`.
51
53
  * @returns Deal
52
54
  * @throws ApiError
53
55
  */
@@ -142,6 +144,36 @@ export declare class DealsService {
142
144
  id: number;
143
145
  requestBody?: DealMoveStageRequest;
144
146
  }): CancelablePromise<Deal>;
147
+ /**
148
+ * Attach a tag to this record
149
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
150
+ *
151
+ * **Required permission:** `Ibl.CRM/Tags/write`.
152
+ * @returns any No response body
153
+ * @throws ApiError
154
+ */
155
+ static dealsTagsCreate({ id, requestBody, }: {
156
+ /**
157
+ * A unique integer value identifying this deal.
158
+ */
159
+ id: number;
160
+ requestBody: _TagAttachRequest;
161
+ }): CancelablePromise<any>;
162
+ /**
163
+ * Detach a tag from this record
164
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
165
+ *
166
+ * **Required permission:** `Ibl.CRM/Tags/write`.
167
+ * @returns void
168
+ * @throws ApiError
169
+ */
170
+ static dealsTagsDestroy({ id, tagId, }: {
171
+ /**
172
+ * A unique integer value identifying this deal.
173
+ */
174
+ id: number;
175
+ tagId: string;
176
+ }): CancelablePromise<void>;
145
177
  /**
146
178
  * Mark a deal as won
147
179
  * Moves the Deal into a closed-won stage and sets `status='won'`. If `stage_code` is omitted, the first `is_won=True` stage in the Deal's pipeline (by sort order) is used.
@@ -27,7 +27,7 @@ export declare class LeadSourcesService {
27
27
  * Create a lead source
28
28
  * Creates a new LeadSource in your Platform. `code` must be unique.
29
29
  *
30
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
30
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
31
31
  * @returns LeadSource
32
32
  * @throws ApiError
33
33
  */
@@ -1,3 +1,4 @@
1
+ import type { _TagAttachRequest } from '../models/_TagAttachRequest';
1
2
  import type { Organization } from '../models/Organization';
2
3
  import type { PaginatedOrganizationList } from '../models/PaginatedOrganizationList';
3
4
  import type { PatchedOrganization } from '../models/PatchedOrganization';
@@ -11,7 +12,7 @@ export declare class OrganizationsService {
11
12
  * @returns PaginatedOrganizationList
12
13
  * @throws ApiError
13
14
  */
14
- static organizationsList({ name, owner, page, pageSize, }: {
15
+ static organizationsList({ name, owner, page, pageSize, tags, }: {
15
16
  name?: string;
16
17
  owner?: number;
17
18
  /**
@@ -22,12 +23,13 @@ export declare class OrganizationsService {
22
23
  * Number of results to return per page.
23
24
  */
24
25
  pageSize?: number;
26
+ tags?: string;
25
27
  }): CancelablePromise<PaginatedOrganizationList>;
26
28
  /**
27
29
  * Create an organization
28
30
  * Creates a new organization in your Platform. The Platform is inferred from your credentials. `name` must be unique within your Platform.
29
31
  *
30
- * **Required permission:** `Ibl.CRM/Organizations/write`.
32
+ * **Required permission:** `Ibl.CRM/Organizations/action`.
31
33
  * @returns Organization
32
34
  * @throws ApiError
33
35
  */
@@ -80,4 +82,28 @@ export declare class OrganizationsService {
80
82
  static organizationsDestroy({ id, }: {
81
83
  id: string;
82
84
  }): CancelablePromise<void>;
85
+ /**
86
+ * Attach a tag to this record
87
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
88
+ *
89
+ * **Required permission:** `Ibl.CRM/Tags/write`.
90
+ * @returns any No response body
91
+ * @throws ApiError
92
+ */
93
+ static organizationsTagsCreate({ id, requestBody, }: {
94
+ id: string;
95
+ requestBody: _TagAttachRequest;
96
+ }): CancelablePromise<any>;
97
+ /**
98
+ * Detach a tag from this record
99
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
100
+ *
101
+ * **Required permission:** `Ibl.CRM/Tags/write`.
102
+ * @returns void
103
+ * @throws ApiError
104
+ */
105
+ static organizationsTagsDestroy({ id, tagId, }: {
106
+ id: string;
107
+ tagId: string;
108
+ }): CancelablePromise<void>;
83
109
  }
@@ -1,3 +1,4 @@
1
+ import type { _TagAttachRequest } from '../models/_TagAttachRequest';
1
2
  import type { PaginatedPersonList } from '../models/PaginatedPersonList';
2
3
  import type { PatchedPerson } from '../models/PatchedPerson';
3
4
  import type { Person } from '../models/Person';
@@ -16,7 +17,7 @@ export declare class PersonsService {
16
17
  * @returns PaginatedPersonList
17
18
  * @throws ApiError
18
19
  */
19
- static personsList({ createdAtGte, createdAtLte, lifecycleStage, metadataHasKey, organization, owner, page, pageSize, }: {
20
+ static personsList({ createdAtGte, createdAtLte, lifecycleStage, metadataHasKey, organization, owner, page, pageSize, tags, }: {
20
21
  createdAtGte?: string;
21
22
  createdAtLte?: string;
22
23
  /**
@@ -40,12 +41,13 @@ export declare class PersonsService {
40
41
  * Number of results to return per page.
41
42
  */
42
43
  pageSize?: number;
44
+ tags?: string;
43
45
  }): CancelablePromise<PaginatedPersonList>;
44
46
  /**
45
47
  * Create a person
46
48
  * Creates a new person in your Platform. The Platform is inferred from your credentials. If `organization` is supplied, it must reference an organization in your Platform.
47
49
  *
48
- * **Required permission:** `Ibl.CRM/Persons/write`.
50
+ * **Required permission:** `Ibl.CRM/Persons/action`.
49
51
  * @returns Person
50
52
  * @throws ApiError
51
53
  */
@@ -126,6 +128,30 @@ export declare class PersonsService {
126
128
  id: string;
127
129
  requestBody: PersonLinkUserRequest;
128
130
  }): CancelablePromise<Person>;
131
+ /**
132
+ * Attach a tag to this record
133
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
134
+ *
135
+ * **Required permission:** `Ibl.CRM/Tags/write`.
136
+ * @returns any No response body
137
+ * @throws ApiError
138
+ */
139
+ static personsTagsCreate({ id, requestBody, }: {
140
+ id: string;
141
+ requestBody: _TagAttachRequest;
142
+ }): CancelablePromise<any>;
143
+ /**
144
+ * Detach a tag from this record
145
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
146
+ *
147
+ * **Required permission:** `Ibl.CRM/Tags/write`.
148
+ * @returns void
149
+ * @throws ApiError
150
+ */
151
+ static personsTagsDestroy({ id, tagId, }: {
152
+ id: string;
153
+ tagId: string;
154
+ }): CancelablePromise<void>;
129
155
  /**
130
156
  * Merge duplicate persons into a primary
131
157
  * Marks each person in `duplicate_ids` as inactive and reports how many related records (deals, activities, tags) were re-parented onto `primary_id`.
@@ -31,7 +31,7 @@ export declare class PipelinesService {
31
31
  * Create a pipeline
32
32
  * Creates a new Pipeline. `code` must be unique within your Platform. Promoting another Pipeline to `is_default=true` while one already exists will fail — unset the existing default first.
33
33
  *
34
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
34
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
35
35
  * @returns Pipeline
36
36
  * @throws ApiError
37
37
  */
@@ -64,7 +64,7 @@ export declare class PipelinesService {
64
64
  * Create a stage
65
65
  * Creates a new PipelineStage in the URL Pipeline. `code` must be unique within that Pipeline. At most one of `is_won` / `is_lost` may be true.
66
66
  *
67
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
67
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
68
68
  * @returns PipelineStage
69
69
  * @throws ApiError
70
70
  */
@@ -0,0 +1,96 @@
1
+ import type { PaginatedTagList } from '../models/PaginatedTagList';
2
+ import type { PatchedTag } from '../models/PatchedTag';
3
+ import type { Tag } from '../models/Tag';
4
+ import type { CancelablePromise } from '../core/CancelablePromise';
5
+ export declare class TagsService {
6
+ /**
7
+ * List tags
8
+ * Returns a paginated list of Tags in your Platform. Supports filtering by `name` (case-insensitive substring) and `created_at__gte`/`created_at__lte` ISO timestamp ranges.
9
+ *
10
+ * **Required permission:** `Ibl.CRM/Tags/list`.
11
+ * @returns PaginatedTagList
12
+ * @throws ApiError
13
+ */
14
+ static tagsList({ createdAtGte, createdAtLte, name, page, pageSize, }: {
15
+ createdAtGte?: string;
16
+ createdAtLte?: string;
17
+ name?: string;
18
+ /**
19
+ * A page number within the paginated result set.
20
+ */
21
+ page?: number;
22
+ /**
23
+ * Number of results to return per page.
24
+ */
25
+ pageSize?: number;
26
+ }): CancelablePromise<PaginatedTagList>;
27
+ /**
28
+ * Create a tag
29
+ * Creates a new Tag in your Platform. `name` must be unique within your Platform; supply `color` as a `#RRGGBB` hex string (defaults to `#888888`).
30
+ *
31
+ * **Required permission:** `Ibl.CRM/Tags/action`.
32
+ * @returns Tag
33
+ * @throws ApiError
34
+ */
35
+ static tagsCreate({ requestBody, }: {
36
+ requestBody: Tag;
37
+ }): CancelablePromise<Tag>;
38
+ /**
39
+ * Retrieve a tag
40
+ * Returns a single Tag by id.
41
+ *
42
+ * **Required permission:** `Ibl.CRM/Tags/read`.
43
+ * @returns Tag
44
+ * @throws ApiError
45
+ */
46
+ static tagsRetrieve({ id, }: {
47
+ /**
48
+ * A unique integer value identifying this tag.
49
+ */
50
+ id: number;
51
+ }): CancelablePromise<Tag>;
52
+ /**
53
+ * Replace a tag
54
+ * Replaces all editable fields on the Tag.
55
+ *
56
+ * **Required permission:** `Ibl.CRM/Tags/write`.
57
+ * @returns Tag
58
+ * @throws ApiError
59
+ */
60
+ static tagsUpdate({ id, requestBody, }: {
61
+ /**
62
+ * A unique integer value identifying this tag.
63
+ */
64
+ id: number;
65
+ requestBody: Tag;
66
+ }): CancelablePromise<Tag>;
67
+ /**
68
+ * Update a tag
69
+ * Updates only the supplied fields on the Tag (typically `name` or `color`).
70
+ *
71
+ * **Required permission:** `Ibl.CRM/Tags/write`.
72
+ * @returns Tag
73
+ * @throws ApiError
74
+ */
75
+ static tagsPartialUpdate({ id, requestBody, }: {
76
+ /**
77
+ * A unique integer value identifying this tag.
78
+ */
79
+ id: number;
80
+ requestBody?: PatchedTag;
81
+ }): CancelablePromise<Tag>;
82
+ /**
83
+ * Delete a tag
84
+ * Deletes the Tag. All attachments to Persons, Organizations, and Deals are removed atomically via cascade.
85
+ *
86
+ * **Required permission:** `Ibl.CRM/Tags/delete`.
87
+ * @returns void
88
+ * @throws ApiError
89
+ */
90
+ static tagsDestroy({ id, }: {
91
+ /**
92
+ * A unique integer value identifying this tag.
93
+ */
94
+ id: number;
95
+ }): CancelablePromise<void>;
96
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@iblai/iblai-api",
3
- "version": "4.266.0-core",
3
+ "version": "4.267.0-core",
4
4
  "main": "dist/index.cjs.js",
5
5
  "module": "dist/index.esm.js",
6
6
  "type": "module",